Hi there,
I am a newbie of WinCE. I have an application which is CFrameWnd based
application. In most cases of PDA, people click the close icon [X] of the
form will only cause the AP to be hidden. However, I have a special PDA
called O2(WM5) which will close my AP whenever the close icon [X] was
clicked. Is there a way to prevent a frame base window to be close on WinCE
?
I tried dialog based AP. In the case of dialog based application , I
overrided the OnOK method, which can stop the CLOSE procedure successfully.
However, In the case of CFrameWnd based application, even though I
overrided the mehtod of CDocument::CanCloseFrame, the application still be
closed. WHY?
Let me wrote simply, hope you can find the place where is not correct.
In the case of CDialog
MyDialog:OnOk() // default close function of a modal dialog
{
// CDialog::OnOk(); <-- mark this line can stop window close procedure
}
In the case of CFrameWnd
MyFrame:OnClose() // close frame window
{
// CFrameWnd::OnClose(); <-- mark this didnt stop the close procedure
}
Is Anything wrong ?
any help is appreciated
Avex