General information
Category:
Object Oriented Programming
>In our application, we use pageframes to accomodate large data entry tasks. To accomodate our customers that don't like mouse-interupts, we have a page-up and page-down utility that is called using the ON KEY PGUP and ON KEY PGDN commands.
>
>This has worked fine, but I have recently discovered some really strange behavior that is new to me (but apparently existing all along). It seems that if we are on an object that has a valid (lostfocus, etc.) method, and press the Page Up key, then the object methods are not executed until the page is loaded the next time.
>
>In our case, this causes program errors to occur when the valid is 'restarted' upon page activate, due to now-incorrect dynamic form properties. It is also causing data to be stored incorrectly for some items, such as measurement conversions.
>
>Is there a standard way to handle this, or does anyone have any ideas how to ensure that the object valid property gets executed prior to leaving a page?
>
>Thanks in advance,
>
>David
You could try using the THISFORM.activecontrol property to call the lostfocus and valid events of the object, in the code called by the ON KEY command. For example:
thisform.activecontrol.lostfocus()
thisform.activecontrol.valid()
Good Luck,
Gerry
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only