Microsoft DirectX 9.0

IDirect3DDevice9::SetDialogBoxMode Method

This method allows the use of Microsoft?Windows?Graphics Device Interface (GDI) dialog boxes in full-screen mode applications.


HRESULT SetDialogBoxMode(      

    BOOL bEnableDialogs );


[in] TRUE to enable GDI dialog boxes, and FALSE to disable them.

Return Value

If the method succeeds, the return value is D3D_OK.

If the method fails, the return value can be D3DERR_INVALIDCALL unless all of the following are true.


The GDI dialog boxes must be created as child to the device window. They should also be created within the same thread that created the device because this enables the parent window to manage redrawing the child window.

The method has no effect for windowed mode applications, but this setting will be respected if the application resets the device into full-screen mode. If SetDialogBoxMode succeeds in a windowed mode application, any subsequent reset to full-screen mode will be checked against the restrictions listed above. Also, SetDialogBoxMode causes all back buffers on the swap chain to be discarded, so an application is expected to refresh its content for all back buffers after this call.

© 2002 Microsoft Corporation. All rights reserved.