Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
.Value synchronization
Message
 
To
25/09/2002 07:41:59
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00704046
Message ID:
00704214
Views:
15
This message has been marked as the solution to the initial question of the thread.
>>>Sometimes when I ask for TextBox.Value, I get a different result than the underlying field, MyTable.MyField. This happens when the user just changed the value.
>>>
>>>If I postpone the check, for instance with a Timer, I get consistent results. Is there a better way to do this?
>>>
>>>TIA, Hilmar.
>>
>>Hilmar,
>>
>>The controlsource is updated after the Valid event fires. Prior to that the value property and controlsource may have different values.
>
>Thanks.
>
>It makes sense, too, if you put it this way.
>
>Now, is there a way to force this synchronization? Perhaps I should invoke MyTextBox.Valid()? Or SomeOtherTextBox.SetFocus()?
>
>Hilmar.

Hilmar,
I achieve this in my Save class with
*-- Force the current controls data buffer to update.
If Type("thisform.ActiveControl") = "O"
	thisform.ActiveControl.SetFocus()
EndIf 
HTH
Caroline
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform