Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

command line instruction...urgent!!!!

Status
Not open for further replies.

swiv

Programmer
Sep 18, 2002
20
GB
Hi I'm trying to execute a .bat file on the server and have tried everything but the thing will not run. I have tried...

dim proc as new Process()
proc.StartInfo.FileName = Server.MapPath( "..\FormTemplates\test2.bat" )

proc.Start()

proc.Kill()

and I have tried

Dim dblRet as Double
dblRet = shell ("C:\c2k\nma\portalvb\FormTemplates\test2.bat" )

neither work...I get no error messages and the page loads and refreshes just fine...cept the .bat file will not execute...any ideas please!!!!


SWIV
 
SWIV,

I haven't actually tried this myself, but I did look into it a little bit for you. Try this:

Dim dblRet as Double
dblRet = shell ("C:\c2k\nma\portalvb\FormTemplates\test2.bat")
AppActivate (dblRet) -----------------------------------------------
"The night sky over the planet Krikkit is the least interesting sight in the entire universe."
-Hitch Hiker's Guide To The Galaxy
 
I really appreciate your help...and I think I see what your trying to do but now I get this error

Overload resolution failed because no accessible 'AppActivate' can be called without a narrowing conversion:

mmmmmmmmm.....

any ideas?

SWIV
 
Right, I found out about Narrowing conversions, but i have a new problem and that is the fact that I get this error message...

Process '3892' was not found.


It can't find the windows process do you think this has something to do with permissions and users?

SWIV
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top