Combo Box not showing Data and need to search sheets based on combo box

Hutch1603

New Member
Joined
Apr 23, 2013
Messages
26
Hello,

I have created a user form that lets me enter data onto different worksheets within the workbook depending on a combobox selection. My problem arises when I click the command button to open the 2nd user form. It opens, but the combobox does not display the entries I want to Show.

Sub UserForm1_Initialize()
With ComboBox1
.AddItem "Tuesday"
.AddItem "Wednesday"
.AddItem "Friday"
.Additem "Saturday"
End With
End Sub

The code above is what I am using and is the same to the code in UserForm, used for the data entry. I have tried to rename the combobox to ComboBox11 and still it wont Work. Also, I have two DTPicker boxes below my combobox. I would like these to be blank until the user selects a date, but I cannot get them to clear. I have tried lots of different code suggestions from multiple web sites, yet nothing works.

Does anyone have an inclining to why my combobox wont display the items and I cant blank the datepicker fields?
 

Excel Facts

Waterfall charts in Excel?
Office 365 customers have access to Waterfall charts since late 2016. They were added to Excel 2019.
It should be
Code:
Sub UserForm_Initialize()
regardless of the name of the userform.
 
Upvote 0
Hi Fluff,

Thank you for that. I din't realise you didn't need to put the user form number in. On another note, do you no how to clear DTPicker Fields so that when the userform opens they are blank. Can't get any of the variations I have googled to work.
 
Upvote 0
I don't think that a date picker can be blank.
 
Upvote 0

Forum statistics

Threads
1,223,961
Messages
6,175,652
Members
452,664
Latest member
alpserbetli

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