Board index » off-topic » Is current record modified?

Is current record modified?


2005-06-01 05:40:31 PM
off-topic19
Hello
I need to enable or disable the button according to the fact if current
record is modified. I tried to use Clientdataset.Modified but it does not
work after scrolling off the record and then back. I always get not
modified. Can any of you help me? The desired behaviour is:
Button is disabled
Edit any field in the record ->enable button
Scroll off the record ->button is set according to the status of currently
active record
scroll back to modified record ->button is enabled
Thanks
Jaro
 
 

Re:Is current record modified?

In Cds.AfterScroll event:
Button.Enabled:=EmplCds.UpdateStatus<>usUnmodified;
Griso wrote:
Quote
Hello

I need to enable or disable the button according to the fact if current
record is modified. I tried to use Clientdataset.Modified but it does not
work after scrolling off the record and then back. I always get not
modified. Can any of you help me? The desired behaviour is:

Button is disabled
Edit any field in the record ->enable button
Scroll off the record ->button is set according to the status of currently
active record
scroll back to modified record ->button is enabled

Thanks
Jaro