the Prompt save message
-
Hallo in my SDI-Application i have the following problem: when i write something and click close or exit the application does not ask me if i want to save the document /file or not(the prompt message does not appear???) please help.
Have you called the document's
SetModifiedFlag()
method?"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
-
Have you called the document's
SetModifiedFlag()
method?"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
i have now the following Code : When i click on the close or exit button, OnDeleteContents() will be called: void CTest_Doc::OnDeleteContents() { CDocument::DeleteContents (); CDocument::OnCloseDocument(); CDocument::SetModifiedFlag(1); } after that there is a heap problem???
-
i have now the following Code : When i click on the close or exit button, OnDeleteContents() will be called: void CTest_Doc::OnDeleteContents() { CDocument::DeleteContents (); CDocument::OnCloseDocument(); CDocument::SetModifiedFlag(1); } after that there is a heap problem???
-
okay i corrected : void CTest_Doc::OnDeleteContents() { CDocument::SetModifiedFlag(1); CDocument::DeleteContents (); CDocument::OnCloseDocument(); } but the Prompt save message stiil not appear??
susanne1 wrote:
but the Prompt save message stiil not appear??
Because you are possibly calling
SetModifiedFlag()
too late. It needs to be called as soon as the document changes."Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons