Home > Software engineering >  SwitchDesktop () will be free to jump out of the back to the original interface that is why, is ther
SwitchDesktop () will be free to jump out of the back to the original interface that is why, is ther

Time:09-25

SwitchDesktop () will be free to jump out of the back to the original interface that is why, is there a way to stay in the generated interface?

CodePudding user response:

Close the original interface explorer. Exe process it one more try,


SwitchDesktop Function

Top service the specified desktop visible and activates it. This enables the desktop to receive input from the user. The calling process must have DESKTOP_SWITCHDESKTOP access to the desktop for the SwitchDesktop function to succeed.


BOOL WINAPI SwitchDesktop (
__in HDESK hDesktop
);

The Parameters
HDesktop
A handle to the desktop. This handle is returned by the CreateDesktop and OpenDesktop functions provides.

This desktop must be associated with the current window station for the process.

The Return Value
If the function succeeds, the return value is nonzero.

If the function fails, the return value is zero. To get extended error information, call GetLastError. An SwitchDesktop only sets the last error for the following cases:


When the desktop belongs to an invisible window station
The When hDesktop is an invalid handle, refers to a destroyed the desktop, or belongs to a company's session than that of the calling process
Few
The SwitchDesktop function fails if The desktop belongs to an invisible window station. The SwitchDesktop braking fails when called from a process associated with a secured The desktop, as to The WinLogon and ScreenSaver desktops.

Requirements
The Client
The Requires Windows Vista, Windows XP, Windows 2000 Professional, or Windows NT Workstation 3.51 and later.

Server
The Requires Windows Server 2008 and Windows Server 2003, Windows 2000 Server, or Windows NT Server 3.51 and later.

The Header
Declared in Winuser. H; The include Windows. H.

The Library
Use User32. Lib.

DLL
The Requires User32. DLL.


See Also
CreateDesktop
Desktops
OpenDesktop
The Window Station and Desktop Functions provides



Send comments about this topic to Microsoft

The Build date: 8/15/2007
  • Related