[DllImport("coredll.Dll")]
public static extern IntPtr FindWindow(string strclassName, stringstrWindowName);
[DllImport("coredll.Dll")]
public static extern int SetWindowPos(IntPtr hwnd, int hWndInsertAfter, intx, int y, int cx, int cy, int wFlags);
[DllImport("coredll.Dll")]
public static extern bool ShowWindow(IntPtr hWnd, Int32 nCmdShow);
public const int WM_CLOSE = 0x10;
[DllImport("coredll.Dll")]
public static extern int SendMessage(IntPtr hwnd, int wMsg, int wParam, intlParam);
[DllImport("coredll.Dll", EntryPoint ="CreateProcess", SetLastError = true)]
extern static int CreateProcess(stringstrImageName, string strCmdLine, IntPtr pProcessAttributes, IntPtrpThreadAttributes, int bInheritsHandle, int dwCreationFlags, IntPtrpEnvironment, IntPtr pCurrentDir, IntPtr bArray, ProcessInfooProc);
public class ProcessInfo
{
publicInt32 hProcess;
public Int32 hThread;
public Int32 ProcessID;
publicInt32 ThreadID;
}
[DllImport("coredll.Dll")]
public static extern boolMoveWindow(IntPtr hWnd, int x, int y,int nWidth, int nHeight, bool bRePaint);