Personal computing discussed

Moderators: renee, SecretSquirrel, just brew it!

 
steelcity_ballin
Gerbilus Supremus
Topic Author
Posts: 12072
Joined: Mon May 26, 2003 5:55 am
Location: Pittsburgh PA

Command line access from web

Fri Jul 31, 2009 12:02 am

So I had to write a quick and dirty little app vb (asp.net) to hook into the command line passing some stuff, and read back in the results. Seemed easy enough. There are essentially 2 commands involved, the first changes the drive and directory, the second calls a program with parameter and waits for results.

If i run my command consisting of these things (essentially 2 commands) with only 1 input string (you can separate commands with the ampersand) it works and returns my results perfectly. However, from the web I think I have issues with it incorrectly parsing double quotes and things of this nature. The strange thing is, if instead of calling the command line I write out the call I WOULD have made to a text file, open said text file, copy and paste into the command line, it works just fine. Strange!? Ideas?
 
steelcity_ballin
Gerbilus Supremus
Topic Author
Posts: 12072
Joined: Mon May 26, 2003 5:55 am
Location: Pittsburgh PA

Re: Command line access from web

Fri Jul 31, 2009 5:47 am

Early morning bump!
 
wibeasley
Gerbil Elite
Posts: 952
Joined: Sat Mar 29, 2008 3:19 pm
Location: Norman OK

Re: Command line access from web

Sun Aug 23, 2009 2:07 pm

Did you figure this out yet?

It runs fine from a .NET console application, but not an ASP.NET application? Currently are they both being run on your desktop? ANy chance the asp program is encoding the text different than the console application?

I had some screwy thing like that once, and I think the cause turned out to be that one of the roads had a stricter limitation on the number characters allowed in the opening arguments -so it was truncating the string silently.

Who is online

Users browsing this forum: No registered users and 20 guests
GZIP: On