Thank you for your response.
Even after setting error code to 0 SetLastError(0); before calling CreateProcessAsUser(), I am still getting the last error-code as 1813, But the process initiated without any issues.

Now I am coming to the real problem I am facing.

Actually we are working on a remote application, where we run the host process with CreateProcessAsUser(). Later from our application if we pass Ctrl+Alt+Del command we are getting UAC screen where we can LogOff the desktop. But on clicking LogOff the system getting crashed(blue screen). But this is not happening if I Log off the remote machine from Start menu of Windows(Start->Logoff) This is happening in Vista/Windows7.

Could you please throw some light on the issue?


Regards
Sreeni