Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Remove blank rows from combobox
Hi all. I have a userform with comboboxes in it. I populate the combobox
with the following code: Sub Show_UserForm() UserForm1.ComboBox1.List = Worksheets("Data Tables").Range("A4:A30").Value UserForm1.ComboBox2.List = Worksheets("Data Tables").Range("B4:B30").Value UserForm1.ComboBox3.List = Worksheets("Data Tables").Range("C4:C30").Value UserForm1.ComboBox4.List = Worksheets("Data Tables").Range("D4:D30").Value UserForm1.Show End Sub The range it is reading from is larger than the number of data entries. I wanted to allow for the user to add an entry to the combobox pulldown without having to manipulate code. Can I still allow for this, but at the same time NOT show 20 blank rows in the combobox pulldown?? Thanks for your help! |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Remove blank rows from combobox
Hi guys. Never mind.....I should have known this!!
UserForm1.ComboBox1.List = Worksheets("Data Tables").Range("A4:A" & Range("A65536").End(xlUp).Row).Value Thanks anyway! "Steph" wrote in message ... Hi all. I have a userform with comboboxes in it. I populate the combobox with the following code: Sub Show_UserForm() UserForm1.ComboBox1.List = Worksheets("Data Tables").Range("A4:A30").Value UserForm1.ComboBox2.List = Worksheets("Data Tables").Range("B4:B30").Value UserForm1.ComboBox3.List = Worksheets("Data Tables").Range("C4:C30").Value UserForm1.ComboBox4.List = Worksheets("Data Tables").Range("D4:D30").Value UserForm1.Show End Sub The range it is reading from is larger than the number of data entries. I wanted to allow for the user to add an entry to the combobox pulldown without having to manipulate code. Can I still allow for this, but at the same time NOT show 20 blank rows in the combobox pulldown?? Thanks for your help! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How do I remove LOTS of blank rows at once | Excel Discussion (Misc queries) | |||
Remove Blank and Non Data Rows | Excel Discussion (Misc queries) | |||
formula to remove blank rows | Excel Discussion (Misc queries) | |||
How do I remove blank rows in Excel? | Excel Discussion (Misc queries) | |||
remove all blank or empty rows | Excel Programming |