List Names of All ActiveX Objects on Sheet

EldrckTW

New Member
Joined
Mar 10, 2008
Messages
34
Hi all,

I'm looking for a simple vba code that will put all object names from a sheet into a list in column A. For example, the list would look like:

ComboBox1
ComboBox2
ComboBox3
SpinButton1
SpinButton2
...

I've been searching for a while with no luck. Anyone have any ideas?

Thanks!
 

Excel Facts

How can you turn a range sideways?
Copy the range. Select a blank cell. Right-click, Paste Special, then choose Transpose.
Came across this code...so far works for what I'm looking for, but may need to tweak a bit. If there's a cleaner way to do this I would love to hear.

Code:
    Range("A1").Select
    Dim PicObj As Object
    For Each PicObj In ActiveSheet.Shapes
        MyType = TypeName(PicObj.OLEFormat.Object)
        ActiveCell.Value = PicObj.Name
        ActiveCell.Offset(1, 0).Select
    Next PicObj
 
Upvote 0

Forum statistics

Threads
1,226,729
Messages
6,192,696
Members
453,747
Latest member
tylerhyatt04

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