Creating a Combo Box on a UserForm using VBA

brockvilleal

New Member
Joined
Aug 19, 2004
Messages
47
I am new to this. I have searched but am still puzzled.

I have created a userform (frmgrade) with a combo box and a text box. I need to first off populate this combo box (found in workbook pick.xls) with a list from another workbook (defn.xls). This list will have 6 items. I want the user to select from the drop down list, one of these 6 items. When that item is selected, I want the definition for that item to appear in the text box.

The 6 items are found in defn.xls, sheet "plist", range b4:b9
The 6 definitions are found in defn.xls sheet "plist" range c4:c9

Where would I place the code? I thought it should go in the forms itself.

Thanks,

Al
 

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
I would put it into the UserForm_Initialize() section of code (you can get at that from the UserForm in the VBA).
 
Upvote 0

Forum statistics

Threads
1,214,952
Messages
6,122,454
Members
449,083
Latest member
Ava19

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top