Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can A ComboBox (In A Grid) Automatically Open Up When GotFocus

Status
Not open for further replies.

drosenkranz

Programmer
Sep 13, 2000
360
US
Hello,

I have a combobox which slects and stores ID numbers for household members in an application process. The field is an integer in the household member's table.

I'd like the user to be able to see the contents of this combobox (Style = 2) when they tab onto it in a grid. Because the combobox is displaying a number, the leading spaces are larger that my combobox so you can't see the value in the box until you open the combobox by pressing <F4> key (or until you leave that box again).


Is there a way to get a combobox (that's embedded in a grid) to automatically open up when the user tabs onto that control - without making the user manually press the <F4> key to open the combobox?

Thanks,

Dave

The 2nd mouse gets the cheese.
 
Hi Dave,

In the combobox GotFocus event you can code:

KEYBOARD '{F4}'

Jim
 
while jimstarr's answer is absolutely correct, I'm going to point you to a FAQ with the same answer.

How do I programmatically make a combobox drop-down?
faq184-118

If you search the FAQ area and/or do a Keyword Search on this forum first you will save yourself some time. There's not much that hasn't been answered out here before.

Slighthaze = NULL
craig1442@mchsi.com
&quot;Whom computers would destroy, they must first drive mad.&quot; - Anon​
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top