merlin007
asked on
how to read the itemdata of a selected item in combo
I have entered a long as itemdata as I loaded the combo box. Now when the user selects an option in the combo i want to be able to read the corresponding value I loaded in the itemdata property.
I cannot find any info on this.
Can anyone help
Thanks
Merlin007
I cannot find any info on this.
Can anyone help
Thanks
Merlin007
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Modify third line as
Msg = Msg & Combo1.List(Combo1.ListInd ex)
Msg = Msg & Combo1.List(Combo1.ListInd
ASKER
Thanks
Merlin007
Merlin007
Dim lListIndex as long
if combo.listINDEX <>-1 then
lListIndex=combo.itemdata( combo.list index)
end if
if combo.listINDEX <>-1 then
lListIndex=combo.itemdata(
end if
ASKER
sorry sudarshan shir, I had awarded the points before your answer came in. I am however using your code.
Thanks everyone
merlin007
Thanks everyone
merlin007
MsgBox Combo1.ItemData (Combo1.ListIndex)
End Sub