Compartilhar via


CKeyboardManager::SaveState

Saves the shortcut key tables to the Windows registry.

BOOL SaveState(
   LPCTSTR lpszProfileName = NULL,
   CFrameWnd* pDefaultFrame = NULL
);

Parameters

  • [in] lpszProfileName
    The registry path for saving the CKeyboardManager state.

  • [in] pDefaultFrame
    A pointer to a frame window that becomes the default window.

Return Value

Nonzero if the keyboard manager state was saved successfully, or 0 otherwise.

Remarks

If the lpszProfileName parameter is NULL, this method will write the CKeyboardManager state to the default location specified by the CWinAppEx Class. If you specify a location, you can load the data later using the method CKeyboardManager::LoadState.

If you do not specify a default window, the main frame window will be used as the default window.

Requirements

Header: afxkeyboardmanager.h

See Also

Reference

CKeyboardManager Class

Hierarchy Chart

CWinAppEx Class

CKeyboardManager::LoadState