Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Forms click event fires instead of objects event
Message
From
22/09/2009 14:49:07
 
 
To
22/09/2009 09:26:01
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Vista
Network:
Windows XP
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01425578
Message ID:
01425628
Views:
111
>I am gettting strange behaviour on a form;
>
>The form is a complex form with a pageframe, a number of containers and a mix of labels, textboxes, ActiveX controls, comboboxes and buttons in the container. Some of the objects are instantiated at run time, some at design time.
>
>The form is called from a number of different locations, sometimes to edit an existing record and sometimes to enter a new record.
>
>The problem is that on some calls to the form, the form is activated, keyboard input works fine but mouse activity does not. If I turn event tracing on I see that the mouseover() event fires on all controls BUT when I press the mouse button the click() event of the form fires instead of the individual controls event.
>
>I can't click on buttons or on combobox dropdown arrows, each fires the forms click.
>
>I've tried removing the ActiveX controls, tried zorder() calls but no joy. However if I SET STEP ON and step through the .init() and .activate() it works fine.

Can you test on a different computer with a different mouse/mouse driver? Just to eliminate any chance it's hardware/driver related.

It sounds like some part of the mouse operation isn't completing or an event isn't being cleared, and that's affecting the called form. I believe there's a mouse equivalent of CLEAR TYPEAHEAD but I can't find it in a quick search. It may be worth a try.

Another thing that has tripped me up from time to time is putting test code in various events/methods and neglecting to include DODEFAULT(), or inadvertently causing it not to be fired. If you have related events like MouseDown/MouseMove/MouseUp this might cause weird effects.

A SWAG, since you're using ActiveXs have you experimented with AutoYield?

Is LockScreen being toggled anywhere? Any ON KEY LABELs in effect?

Is there any unique code being fired by the calling form before it loses focus? Anything weird in there?
Regards. Al

"Violence is the last refuge of the incompetent." -- Isaac Asimov
"Never let your sense of morals prevent you from doing what is right." -- Isaac Asimov

Neither a despot, nor a doormat, be

Every app wants to be a database app when it grows up
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform