Invoking exe from windows service(COM Exe runs as service)
-
I want to invoke exe(MFC without GUI) from windows service(COM Exe runs as service). I am using CreateProcessAsUser and trying to invoke, it invokes(when it invokes i am writing log) but not visible in taskmanager. I doubt that the exe is getting invoked under "SYSTEM" and that is the reason its not visible in taskmanager and nor it works(obvious). But I want to invoke under "User"(who is logged in). To do so I tried using LogonUser but it needs username and password of user who is logged in machine. That I cant access. Please guide me or give me clue. Requirement is: Exe should run under the user who is logged in. Regards, KTTransfer.
-
I want to invoke exe(MFC without GUI) from windows service(COM Exe runs as service). I am using CreateProcessAsUser and trying to invoke, it invokes(when it invokes i am writing log) but not visible in taskmanager. I doubt that the exe is getting invoked under "SYSTEM" and that is the reason its not visible in taskmanager and nor it works(obvious). But I want to invoke under "User"(who is logged in). To do so I tried using LogonUser but it needs username and password of user who is logged in machine. That I cant access. Please guide me or give me clue. Requirement is: Exe should run under the user who is logged in. Regards, KTTransfer.
Interaction between services and user-objects is difficult to achieve and also it is not advised that you do it. Note finally that there is a service property in the "connection tab" in the SCM interface that you may have to enable. Good luck.
Easy Profiler : Now open source ! http://www.codeproject.com/KB/cpp/easyprofiler.aspx