If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > PC based Database Applications > Microsoft Excel > combo box txt size

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 02-04-04, 17:43
ben2001 ben2001 is offline
Registered User
 
Join Date: Jan 2004
Posts: 17
combo box txt size

how do you change the size of the text in a combo box?
Ben
Reply With Quote
  #2 (permalink)  
Old 02-04-04, 19:35
Smitty Smitty is offline
Registered User
 
Join Date: Dec 2003
Location: San Diego, CA
Posts: 153
If it's a Forms ComboBox, you don't. Increasing screen zoom is about it.

If it's a Control Toolbox ComboBox, select Properties-->Font and adjust from there.

Hope that helps,

Smitty
Reply With Quote
  #3 (permalink)  
Old 02-05-04, 07:24
ben2001 ben2001 is offline
Registered User
 
Join Date: Jan 2004
Posts: 17
Question

Control Toolbox ComboBox is what i need. but im not sure how the information is inputted into the combo box ? ? ? please help!
Ben
Reply With Quote
  #4 (permalink)  
Old 02-05-04, 12:11
Smitty Smitty is offline
Registered User
 
Join Date: Dec 2003
Location: San Diego, CA
Posts: 153
Are you using a UserForm or are your controls placed directly on the spreadsheet?

Either way, ActiveX controls (those created from the Control Toolbox) have their own VBA code associated with them. In Design mode, double click the control and VBA will open with:

Private Sub ComboBox1_Change()

End Sub

From there, look at the AddItem Method for populating the combo Box. I.E.

Code:
Private Sub ComboBox1_Click()
    With ComboBox1
        .AddItem "Office 1"
        .AddItem "Office 2"
        .AddItem "Office 3"
        .AddItem "Office 4"
        .AddItem "Office 5"
    End With
End Sub

Private Sub ComboBox1_Change()
    '  Return the selection to the worksheet
    Range("B1") = ComboBox1
End Sub
Hope that helps,

Smitty
Reply With Quote
  #5 (permalink)  
Old 02-05-04, 13:16
ben2001 ben2001 is offline
Registered User
 
Join Date: Jan 2004
Posts: 17
hi again!
do you think you could create an example because i cant get it to work. thank you..
Ben
Reply With Quote
  #6 (permalink)  
Old 02-05-04, 13:28
Smitty Smitty is offline
Registered User
 
Join Date: Dec 2003
Location: San Diego, CA
Posts: 153
Here's an example of a Control Toolbox ComboBox, a Forms ComboBox and a User Form ComboBox.

Hope that helps,

Smitty
Attached Files
File Type: zip combobox.zip (13.2 KB, 39 views)
Reply With Quote
  #7 (permalink)  
Old 02-05-04, 14:36
ben2001 ben2001 is offline
Registered User
 
Join Date: Jan 2004
Posts: 17
Quote:
Originally posted by Smitty
Here's an example of a Control Toolbox ComboBox, a Forms ComboBox and a User Form ComboBox.

Hope that helps,

Smitty
thank you this is a great help
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On