I am using VC++ 6 and I have an following MFC app. There is an app iobject and a property sheet class. On InitInstance in the app object I call the property sheets DoModal(); function.
What I am trying to do is when the the DoModal returns IDOK, i want to save some application settings to the registry. But I have an error that is bugging me. the error and the code I use are below
// TheApp class used for the main application
class TheApp : public CWinApp
virtual BOOL InitInstance()
m_pMainWnd = &ps;
if (ps.DoModal() == IDOK)
Note: Page1 is a property class where the function is defined and it is the member variables of Page1 I want to save to the Registry
This is the compiler output
D:\Junk\LatestVersion\TheApp.cpp(158) : error C2352: 'Page1::SaveAppSettings' : illegal call of non-static member function
d:\junk\latestversion\page1.h(27) : see declaration of 'SaveAppSettings'
Error executing cl.exe.
Can anybody help me.