Hello. Is there a way to indicate that a form view has been modified, lets say when you change data in an edit control? Also, is there a way to check all objects (dialogs, windows, etc.) to see if they have been modified? Thank you.
Printable View
Hello. Is there a way to indicate that a form view has been modified, lets say when you change data in an edit control? Also, is there a way to check all objects (dialogs, windows, etc.) to see if they have been modified? Thank you.
In your CFormView class, add a message handler for the CEdit member, EN_CHANGE. This will be called everytime the edit field is being changed. Inside this function do the following.
GetDocument()->SetModified();
Then when you are leaving the CFormView class, then just call
GetDocument()->IsModified()
This will let you know if anything has been modified.
Hope that helps,
Wayne