Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to prevent container to lose focus
Message
 
 
To
07/01/2005 16:51:20
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Environment versions
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Miscellaneous
Thread ID:
00974182
Message ID:
00975732
Views:
19
>Hi Nadya,
>
>You are absolutely right. I didn't check properly before butting in, sorry.
>
>I know you have solved your problem now, but I still wanted to emulate your problem, so I created a container class, added the standard MS _olecalendar control plus a text box and place the following in the LostFocus method of the _olecalendar control
>
>IF This.Object.DayOfWeek = 1
>   WAIT WINDOW 'Sundays not allowed' TIMEOUT 3
>   NODEFAULT
>ENDIF
>
>When I added the class to a form and ran it, it worked as expected, preventing me from moving the cursor to the text box.
>
>Have I misunderstood or is there something different about the Active X controls we are using?
>
>Alan

The difference is I put nodefault in the Container LostFocus event, not the ActiveX control LostFocus, because I delegated the validation logic to container object.
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform