R
Ripan
I have come across a strange error.
I have a userform set up with 5 comboboxes. Each box has its item
populated when you load the form based on the contents of a range on
worksheet. I use the following code to update the combobox (ctl is th
combobox to be populated):
Dim i As Integer 'loop counter
ctl.Clear
PopulateReviewerList fileList
With Worksheets("Reviewer Data")
For i = 1 To ArrayMethods.Size(fileList) - 1
ctl.AddItem .Cells(fileList(i), 2).Value & " - "
.Cells(fileList(i), 3).Value
Next i
End With
Once the form is loaded, a second function sets the value of the for
to be the value of a cell on a spreadsheet according to this code (it'
generic to reduce confusion):
cbx.Value = Cells(x,y).Value
I encounter a runtime error whenever the cell value is not one of th
values preloaded into the box, even though the matchrequired propert
is set to false. If the value matches one in the box, then there is n
issue.
I want the combobox to be able to be set to any value. Can someone hel
me with this?
Regards,
Ripa
I have a userform set up with 5 comboboxes. Each box has its item
populated when you load the form based on the contents of a range on
worksheet. I use the following code to update the combobox (ctl is th
combobox to be populated):
Dim i As Integer 'loop counter
ctl.Clear
PopulateReviewerList fileList
With Worksheets("Reviewer Data")
For i = 1 To ArrayMethods.Size(fileList) - 1
ctl.AddItem .Cells(fileList(i), 2).Value & " - "
.Cells(fileList(i), 3).Value
Next i
End With
Once the form is loaded, a second function sets the value of the for
to be the value of a cell on a spreadsheet according to this code (it'
generic to reduce confusion):
cbx.Value = Cells(x,y).Value
I encounter a runtime error whenever the cell value is not one of th
values preloaded into the box, even though the matchrequired propert
is set to false. If the value matches one in the box, then there is n
issue.
I want the combobox to be able to be set to any value. Can someone hel
me with this?
Regards,
Ripa