private static extern bool CreateProcess( string lpApplicationName, string lpCommandLine, ref SecurityAttributes lpProcessAttributes, ref SecurityAttributes lpThreadAttributes, bool bInheritHandles, uint dwCreationFlags, IntPtr lpEnvironment, string lpCurrentDirectory, [In] ref StartupInfo lpStartupInfo, out ProcessInformation lpProcessInformation);
public ProcessInfo( Process ps, ProcessInformation psi) { if (null == ps) { throw new ArgumentNullException("ps"); } this.ps = ps; this.mainThreadHandle = new SafeWaitHandle( psi.hThread, true); }