2 word items in ActiveX combobboxes using vba?

fedi4

New Member
Joined
Apr 8, 2013
Messages
6
Hi everyone!

I'm very new beginner to vba in excel, but I’ve tried to put up 3 combo boxes that are dependent on each other so that what you select in one appear in another combo box, and I got this working using only single words, but when I put in 2 words example “ Cats and Dogs” it doesn’t work anymore… Can someone please help me out with this, coz I really need this to work to continue making my combo boxes work in my sheet.
 

Excel Facts

Will the fill handle fill 1, 2, 3?
Yes! Type 1 in a cell. Hold down Ctrl while you drag the fill handle.
Posting your code would be a good start.

Its in combobox 3 that contains 2 word items so it cant send the name range list that is connected forward.
I'm using ranged name list so i dont know if it helps so mutch with my code, but her it is :

PHP:
Private Sub ComboBox3_KeyDown(ByVal KeyCode As MSForms.ReturnInteger, ByVal Shift As Integer)

End Sub

Sub WorkSheet_Activate()
 
Worksheets(1).OLEObjects("ComboBox1").ListFillRange = "Data"
ComboBox1.ListIndex = 0
 
End Sub

Private Sub ComboBox1_Change()
Me.ComboBox2.Value = ""
Me.ComboBox2.ListFillRange = Me.ComboBox1.Value
End Sub

Private Sub ComboBox2_Change()
Me.ComboBox3.Value = ""
Me.ComboBox3.ListFillRange = Me.ComboBox2.Value
End Sub
Private Sub ComboBox3_Change()
Me.ComboBox4.Value = ""
Me.ComboBox4.ListFillRange = Me.ComboBox3.Value

Range("L5").Value2 = ComboBox3.Value
End Sub
Private Sub ComboBox4_Change()
Range("L6").Value2 = ComboBox4.Value
End Sub
 
Upvote 0

Forum statistics

Threads
1,214,824
Messages
6,121,783
Members
449,049
Latest member
greyangel23

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