Click to See Complete Forum and Search --> : Detecting changes of Controls


April 11th, 1999, 12:04 PM
Hi there,

in my FormView-based application, i have to store the contents/the state of editcontrols, comboboxes and other controls in a database, if the contents of the control
has been changed by the user.
Is there a very common way to detect, if the contents of a control has been changed ??
I tried to overwrite the PreTranslateMessage(..) function, but i do not find a way to detect if for example a user drags a text in a Editfield....

so i would be very happy if someone could give me a hint for solving this problem.

Thanks in advance

Thomas.

LALeonard
April 11th, 1999, 01:58 PM
Could you store the original values in OnCreate( ), and then compare them when you need to?

LA Leonard - Definitive Solutions, Inc.

Masaaki
April 11th, 1999, 03:41 PM
Hi.

You can check what kind of messages each control has by class wizard.
For example,
Edit box has EN_CHANGE and Listbox has LBN_SELCHANGE.

I just use EN_CHANGE to make the button enabled when I input something in editbox.
So check the content of each message in order to be satisfied with your desire.

Hope for help.
-Masaak Onishi-