Thread: smart button
View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
William[_2_] William[_2_] is offline
external usenet poster
 
Posts: 227
Default smart button

Hi Al

Assuming you have a button called "MyButton" on Sheet1 then

Sub test()
With Sheets("Sheet1")
MsgBox .Buttons("MyButton").TopLeftCell.Address
MsgBox .Buttons("MyButton").BottomRightCell.Address
End With
End Sub

--

XL2003
Regards

William



"Big Al" wrote in message
...
can a button know what cell it is located? I realize that a button can be
shaped and placed anywhere. Perhaps its location can be inferred by its
attributes (coordinates)? If so, how does one fetch these attributes?