Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Is valid event?
Message
From
13/04/1999 09:38:30
 
 
To
12/04/1999 21:40:02
Chong Hanwah
Apic Systems Pteltd
Singapore, Singapore
General information
Forum:
Visual FoxPro
Category:
Other
Title:
Miscellaneous
Thread ID:
00207372
Message ID:
00207790
Views:
12
>>>I had created a class method which setfocus to the
>>>first control of a form. But this method will give
>>>error if called within the 'valid' event.
>>>
>>>So how do i check whether the calling
>>>event is a control's 'VALID' event?
>>>
>>>thanks.
>>
>>You can't set focus from the valid event. As Bruce said, use the lostfocus.
>
>Actually, i am creating a generic class method but
>user may use it in the valid event
>=> I need to check for valid event in my class so that
>if in valid event
> do not do the setfocus()
>endif
>
>but my question is how in the code can i check that it is calling
>from valid event?

You could pass a parameter. Another option, although I haven't tried it, is to traverse the program call chain using the PROGRAM() function.
Craig Berntson
MCSD, Microsoft .Net MVP, Grape City Community Influencer
Previous
Reply
Map
View

Click here to load this message in the networking platform