Export (0) Print
Expand All
Expand Minimize

CMDIFrameWndEx::EnableWindowsDialog

Inserts a menu item whose command ID calls a CMFCWindowsManagerDialog dialog box.

void EnableWindowsDialog(
   UINT uiMenuId,
   LPCTSTR lpszMenuText,
   BOOL bShowAllways=FALSE,
   BOOL bShowHelpButton=FALSE 
);
void EnableWindowsDialog(
   UINT uiMenuId,
   UINT uiMenuTextResId,
   BOOL bShowAllways=FALSE,
   BOOL bShowHelpButton=FALSE 
);

[in] uiMenuId

Specifies the resource ID of a menu.

[in] lpszMenuText

Specifies the item's text.

[in] bShowHelpButton

Specifies whether to display a Help button on the windows management dialog box.

[in] uiMenuTextResId

The string resource identifier that contains the item's text string.

Use this method to insert a menu item whose command calls a MDI child window management dialog box (CMFCWindowsManagerDialog Class). The new item is inserted into the menu specified by uiMenuId. Call EnableWindowsDialog when you process the WM_CREATE message.

The following example shows how EnableWindowsDialog is used in the VisualStudioDemo Sample: MFC Visual Studio Application.

	// Enable windows manager:
	EnableWindowsDialog(ID_WINDOW_MANAGER, _T("Windows..."), TRUE);

Header: afxMDIFrameWndEx.h

Show:
© 2014 Microsoft