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 Shaun E on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I make combo box display a value, not a blank?

Status
Not open for further replies.

staciann

IS-IT--Management
Nov 1, 2006
72
US
I have created several combo boxes that synchronize and populate based on the choice made in the boxes before them. All of them have multiple choices. No default value is ever given, the user must click to view all the choices on the dropdown. They work great.

Here's the problem: I am now working on a form where the last combo box does not have multiple choices - only one option is available. The user chooses the country, then the phone code for the country is displayed in front of the phone number. It works, it displays the proper phone code, but the user must click down on the box...it doesn't just appear as the default when the country is chosen.

How do I get the last combo box to just display the phone code after the country is chosen instead of making them click on the dropdown?

Please help! Thank you!
Staci
 
Perhaps this ?
Me![last combo].SetFocus
Me![last combo].ListIndex = 0

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
on the form Load or anywhere you want this to hapen type this

Combo1 = Combo1.Column (0,0)


I will try my best to help others so will others do!!!!!
IGPCS
Brooklyn, NY
 
I think if you make it a text box instead of a combo box that might help.

that is, unless you want to be able to select either the country or the phone code and display the other.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top