Thanks for your response and cracked as per your advise...thanks a lot @echo off
REM input: textfile addr.txt with IP,name,interface (one per line)
REM values delimited by commas, comments star...
See more...
Thanks for your response and cracked as per your advise...thanks a lot @echo off
REM input: textfile addr.txt with IP,name,interface (one per line)
REM values delimited by commas, comments start with #
REM redirect output to a batch command file for uploading to a Fortigate
echo config router static
for /f " eol=# tokens=1-4 delims=," %%i in (addr2.txt) do CALL :oneaddr %%i %%j %%k %%l
echo end
goto :EOF
:oneaddr
echo edit %1
echo set dst %2
echo set gateway %3
echo set distance 10
echo set device %4
echo next #SNO,Network,Nexthop,Port