I have found a very useful script here that will parse in arguments to a batch file and process them as follows:
BatchFile.btm /a /b:22 /longopt Parm1 Parm2 /quotedArg:"long quoted arg" - OPTION_a will equal 1. - OPTION_b will equal 22 - OPTION_quotedArg will equal "long quoted arg" - OPTION_longopt will eqal 1. - PARAM_1 will equal Parm1 - PARAM_2 will equal Parm2 - PARAM_0 will be set to the number of parms, so 2 in this case
However, this script is written for .btm files and doesn't seem to be suitable for the DOS emulator or more recent versions of Windows. Can anyone translate this or know where to find an up-to-date equivalent that will work in DOS emulator in Win7/Svr2003?