2019-04-21 12:17:31 UTC
parameter is double-quoted or not, and I need to make a launcher script for
The problem is that WshArguments object strips any double-quote enclosures
from the parsed parameters, and there seem to be a way to know whether a
parameter was originally double-quoted or not in the command line. e.g. when
the command line is like below.
launcher.vbs abc "def ghi" "jkl"
Parameter #0 is: abc
Parameter #1 is: def ghi
Parameter #2 is: jkl
In this case, the meaning of parameter #2 would be different from the
program because it's not double-quoted. So, I can't pass it to the program
So, is there a trick to get the parameters without their double-quote
enclosures stripped out? Or get the whole original unparsed command line? So
that I can manually parse it.
I thought about using WMI to retrieve the whole command line, but I haven't
found a reliable way to uniquely identify the current script's process, for
use in the WMI query.