CWinApp::SetRegistryKey

voidSetRegistryKey(LPCTSTRlpszRegistryKey**);**

voidSetRegistryKey(UINTnIDRegistryKey**);**

Parameters

lpszRegistryKey

Pointer to a string containing the name of the key.

nIDRegistryKey

ID/index of a key in the registry.

Remarks

Causes application settings to be stored in the registry instead of INI files. This function sets m_pszRegistryKey, which is then used by the GetProfileInt, GetProfileString, WriteProfileInt, and WriteProfileString member functions of CWinApp. If this function has been called, the list of most recently-used (MRU) files is also stored in the registry. The registry key is usually the name of a company. It is stored in a key of the following form: HKEY_CURRENT_USER\Software\<company name>\<application name>\<section name>\<value name>.

CWinApp OverviewClass MembersHierarchy Chart

See Also   CWinApp::InitInstance, CWinApp::GetProfileInt, CWinApp::GetProfileString, CWinApp::WriteProfileInt, CWinApp::WriteProfileString