DBALUKE HUANG
DBALUKE HUANG

Reputation: 257

How can I skip first 6 lines and the last line in Batch file when I use for /f?

How can I skip first 6 lines and the last line in Batch file when I use for /f?

for /f "tokens=1,2,3,6,7 skip=6 delims= " %%f in (%FILE_LIST%) do (
Set "FFNAME=%%i_%%j"
Set "FFNAME=!FFNAME:-=!"
Set "FFNAME=!FFNAME::=!"
Set "FFNAME=!FFNAME:~,15!"
IF %%f>=100 (
        java -jar D:\HDLdi2.3.9\lib\oracle.ucm.fa_client_11.1.1.jar DownloadTool --dID=%%f --url=%UCM_Link% --username=%_UserName% --password=%_Password% "--outputfile=E:\FusionData\Outbound\%PROPERTY%\Temp\%FILE_NAME%_!FFNAME!.txt"
 )
)

Because the last line doesn't contain the useful infomation what I need. Thanks,

Upvotes: 0

Views: 218

Answers (1)

Compo
Compo

Reputation: 38622

You could perhaps try this instead:

IF %%f GEq 100 (

Upvotes: 1

Related Questions