解决方案 »

  1.   

    CreateDesktop
    The CreateDesktop function creates a new desktop on the window station associated with the calling process. It returns a handle that can be used to access the new desktop. The calling process must have an associated window station, either assigned by the system at process creation time or set by SetProcessWindowStation. A desktop is a secure object contained within a window station object. A desktop has a logical display surface and contains windows, menus, and hooks.HDESK CreateDesktop(
      LPCTSTR lpszDesktop,    // name of the new desktop
      LPCTSTR lpszDevice,     // reserved; must be NULL.
      LPDEVMODE pDevMode,     // reserved; must be NULL
      DWORD dwFlags,          // flags to control interaction with other 
                              // applications
      DWORD dwDesiredAccess,  // specifies access of returned handle
      LPSECURITY_ATTRIBUTES lpsa  // specifies security attributes of 
                                  // the desktop
    );