[Mono-list] Command line parameters with spaces
karolo84 at binkmail.com
Thu Jan 20 15:42:30 EST 2011
Dear list / forum,
I have tried to figure out the following by myself but so far I wasn't
lucky: I have a .NET program that takes a SQL query as command line
argument. If I now run that program under Windows, I simply quote the string
and everything is fine:
app.exe "SELECT foo FROM bar WHERE time='20090212';"
But I have not yet successfully got that running under Linux + Mono. In fact
I haven't even successfully submitted a simple space containing string to
I tried thing like
mono app.exe "a b"
mono app.exe "a\ b"
mono app.exe 'a b'
-> all received as two strings: a and b
mono app.exe ´a b´
-> UTF-8 encoding error
mono app.exe `a b`
-> tries to execute a
What can I do to pass a SQL query as a command line argument to my program?
Searching the forum and with google pointed to Mono.Options but that is the
developer side of the problem, not the app users side... Reflector says the
app just uses plain old args to determine the number of parameters...
View this message in context: http://mono.1490590.n4.nabble.com/Command-line-parameters-with-spaces-tp3228447p3228447.html
Sent from the Mono - General mailing list archive at Nabble.com.
More information about the Mono-list