ASP 1.1 - StandardOutput from console application

  • Thread starter Thread starter Harald Fichtner
  • Start date Start date
H

Harald Fichtner

Hello,

I tried the following code with ASP 1.1 to get the StandardOutput, but it
didn't work.
Who knows what's wrong?

Try
Dim file As String = Server.MapPath("test.exe")
Dim myProcess As New Process
myProcess.StartInfo.FileName = file
myProcess.StartInfo.CreateNoWindow = True
myProcess.StartInfo.UseShellExecute = False
myProcess.StartInfo.RedirectStandardOutput = True
myProcess.Start()
Response.Write(myProcess.StandardOutput.ReadToEnd.ToString)
Catch ex As Exception
Response.Write(ex.Message)
End Try


Thanks for any help

Harald
 
Most likely a security issue. Try the code in a console app where it runs
under you account. If it works (most likely will), you have a security
issue.

--
Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA
http://gregorybeamer.spaces.live.com

*************************************************
Think outside of the box!
*************************************************
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top