Calling a new process from ASP.NET web page

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • bienwell

    Calling a new process from ASP.NET web page

    Hi all,

    I want to call a new process that sends email from the ASP.NET program. This
    process runs in background and does not affect the performance of the
    ASP.NET page .What I did was to develop a console application and complile
    it to have an exe file. In ASP.NET page I call this exe file. Here is the
    code to call this process from the ASP.NET page

    Dim theTest As System.Diagnost ics.Process = New System.Diagnost ics.Process()

    Dim i As System.Diagnost ics.ProcessStar tInfo = New
    System.Diagnost ics.ProcessStar tInfo()

    i.FileName = Directory.GetCu rrentDirectory. ToString & "\EmailApp. exe"

    i.Arguments = "email_addr ess parameter1 parameter2"

    i.CreateNoWindo w = True

    i.UseShellExecu te = False

    theTest.StartIn fo = i

    theTest.Start()

    and the error "The system cannot find the file specified" was pointed to
    this TheTestStart()

    Please provide the rcorrect source codes if you can.

    Thanks in advance.









Working...