How to read the contents of an OLEObject (dropdown list) in excel

F

FurRelKT

I used this code

Sub listcontents()
Dim OLEObj As OLEObject
For Each OLEObj In ActiveSheet.OLEObjects
If TypeOf OLEObj.Object Is MSForms.HTMLSelect Then
Debug.Print OLEObj.Name
Debug.Print OLEObj.progID
End If
Next OLEObj


End Sub

to get the following return.

HTMLSelect1
Forms.HTML:Select.1

I would like to undertand.. as i know this is an OLEObject, i want to
read this list to other worksheet cells. Is that possible to read from
the list? This was a copy/paste from a secure website. the list came
over into excel as a dropdown list.

If more information is needed please ask. The solution i need to be
able to read the contents of this list and display them in another
sheet in the cells, say column A, rows 2 - x.

Thanks for any help.

Keri
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top