cmd - Batch code for execution of .exe files with parameters -


my command line arguments question

getpkt.exe 15-05-14.dlf

the getpkt.exe file , .dlf file in same folder. copy batch file same location , double click that. need execute command.

the folder contains 1 getpkt.exe , 1 .dlf file. .dlf file name varies every time.

so me batch script code need execute following getpkt.exe file the.dlf file in same folder?

thanks in advance.

  1. goto correct path

  2. get filename (if there more one, last one)

  3. execute program filename parameter

    cd /d "c:\path getpkt"

    for /f %%i in ('dir /b *.dlf') set file=%%i

    getpkt.exe %file%


Comments

Popular posts from this blog

commonjs - How to write a typescript definition file for a node module that exports a function? -

openid - Okta: Failed to get authorization code through API call -

ios - Change Storyboard View using Seague -