CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Feb 2011
    Posts
    5

    How to run exe program from windows service using c#

    Hello,

    How to run exe program from windows service using c#.
    This is mycode:

    System.Diagnostics.Process.Start(@"E:\PROJECT XL\INI SQLLOADER\ConsoleApplication2\ConsoleApplication2\ConsoleApplication2\bin\Debug\ConsoleApplication2.exe");

    When i run this service not happening. Please tell me whats wrong with my code. Thanks

  2. #2
    Join Date
    May 2007
    Location
    Denmark
    Posts
    623

    Re: How to run exe program from windows service using c#

    When starting an application from a Windows Service, the application will run within the same environment/session and with the same user privileges as the Windows Service itself. You will therefore not be able to interact with the launched application. It should, however, show up in the Windows Task Manager.
    It's not a bug, it's a feature!

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured