Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Strange behavior of my grid...
Message
From
29/07/1999 12:52:42
 
 
To
29/07/1999 12:40:24
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00247737
Message ID:
00247769
Views:
21
>How do I do to check for focus? Is there any other method then ActiveControl?
>
>/Mårten Törnquist
>
>>The same thing heppens to me. This is, I believe, a known VFP bug. The workaround is to move focus away from the grid before the form refresh. Usually I put code in form refresh() to (1) set .lockscreen = .T., (2) check for focus. (3) if focus is in the grid, move the focus (4) dodefault() to refresh the form, (4) If focus was in the grid, set focus back to the grid, (5) unlock the screen.
>>
>>This seems to do the trick.
>>
>>regards,

You can use activecontrol. But I don't think grids show up in active control, just the textboxes etc in the grid. So you will have to check the grandparent of the activecontrol to see if it is a grid. Its been a while since I looked at this code, so I may be wrong about activecontrol not showing grids.

regards,
Jim Edgar
Jurix Data Corporation
jmedgar@yahoo.com

No trees were destroyed in sending this message. However, a large number of electrons were diverted from their ordinary activities and terribly inconvenienced.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform