I want to run an executable file and a text file. Those files will use some parameters from the client, this executable is on the server.
In DOS it's easy
>file.exe text.txt "users input"
there comes an output on the screen. ^
But i want the output online
I have a code but I dont know how to change it for 2 files in stead of executing 1 file.
<%@ Page Language="vb
<%@ Import Namespace="System.Diagnostics" %>
''Get a file name relative to the current Web app.
Dim file As String = Server.MapPath("file.exe")
'Dim file2 As String = Server.MapPath("regels.style.txt")
Dim info As ProcessStartInfo = new ProcessStartInfo(file, "blaat")
''Redirect output so we can read it.
info.RedirectStandardOutput = true
''To redirect, we must not use shell execute.
info.UseShellExecute = false
''Create and execute the process.
Dim p As Process = Process.Start(info)
''Send whatever was returned through the output to the client.
Response.Write(Replace(p.StandardOutput.ReadToEnd( ), vbCrLf, "<BR />"))
Who wants to help ?