Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Design Question
Message
 
To
11/03/2006 13:00:26
Mike Yearwood
Toronto, Ontario, Canada
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
01103420
Message ID:
01103438
Views:
12
You mean compare the current value against the table value?

Something like this:
**Method: GotFocus
This.iuValueOnGotFocus = This.Value

**Method: LostFocus
IF This.Value # iuValueOnGotFocus
  ThisForm.ValueChanged(This)
ENDIF
>>I have a SetMode method on my baseform class that places the form into either
>>AddMode or EditMode.
>>
>>AddMode is called, of course, when the New Record button is clicked. Edit Mode
>>gets called when the form is opened for editing.
>>
>>In either case, just because the form is up and ready for input doesn't mean the
>>user actually changed something.
>>
>>So I was thinking that in the InteracticeChange method of all data entry controls
>>I could do:
>>
>>
>>ThisForm.ValueChanged(This)
>>
>>
>>The ValueChanged method on the form could then be used to turn on a lChanged
>>property, which would then be checked to see if in fact changes were made.
>>
>>This all would be used in cases where buffering is not enabled.
>>
>>Anyone see any issues with this?
>
>Yep. What happens when the user puts the value back as it was? I'd recommend you have an iuValueOnGotFocus which you can compare to the value during the lost focus and set the flag accordingly.
Everything makes sense in someone's mind
public class SystemCrasher :ICrashable
In addition, an integer field is not for irrational people
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform