Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Container - Selective GotFocus on Click/Tab
Message
From
04/02/2009 17:46:33
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
 
To
04/02/2009 07:14:10
Jay Johengen
Altamahaw-Ossipee, North Carolina, United States
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
01379017
Message ID:
01379370
Views:
14
>>Seems to me that it's as easy as setting the tab order of the container. If the textbox is before the dropdown, it will get focus when you tab.
>>
>>>I have a container that contains a textbox and a dropdown. When the mouse is clicked over the texbox, or the container is tabbed into, I want the textbox to have the focus. When the mouse is clicked over the dropdown, I want that to have the focus. I put code originally into the container.gotfocus like this:
>>>
>>>THIS.EntryTextBox.SetFocus
>>>
>>>But that causes problems when you click over the dropdown, the textbox gets the focus, then a 2nd click allows the dropdown to get the focus. How can I make this work?
>
>It is, and that's what I thought would happen, but for some reason another control in the container is getting the focus. It's actually a fairly complicated class, but I can't seem to find anything changing the Tab Order. Is there anything else that could affect the order coming into a container of controls?

I think Craig had, under "setting the tab order of the container" meant the tab order of the controls inside the container. To check that, rightclick the container and click Edit (or if it's a class unto itself, open that class for editing), and then proceed setting the tab order of the contained controls. Make sure your EntryTextBox has .taborder=1 and you shouldn't need any code.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Reply
Map
View

Click here to load this message in the networking platform