Unable to run macro

Excel Facts

Whats the difference between CONCAT and CONCATENATE?
The newer CONCAT function can reference a range of cells. =CONCATENATE(A1,A2,A3,A4,A5) becomes =CONCAT(A1:A5)
I'd suggest posting the macro here, with what is / isn't happening in the worksheet, BEFORE anyone opens your file !!
 
Upvote 0
Here is the macro
Sub c()
Dim btn As Button
For Each btn In ActiveSheet.Buttons
Debug.Print "Button " & btn.Name & " with caption " _
& btn.Caption & " Located at " & _
btn.TopLeftCell.Address
Next


End Sub
 
Upvote 0
What sort of buttns..., userform,command, activeX, shapes?
your workbook on onedrive doesn't show any buttons !
 
Upvote 0
Rclick on one of them and tell us what it says in the name box (just above column "A")
 
Last edited:
Upvote 0
Try this

Code:
Sub MM1()
For Each cb In ActiveSheet.Buttons
    If TypeName(cb) = "Button" Then
        MsgBox cb.Name & " is located at " & cb.TopLeftCell.Address
    End If
Next cb
End Sub
 
Upvote 0

Forum statistics

Threads
1,214,959
Messages
6,122,476
Members
449,087
Latest member
RExcelSearch

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