View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Guabble Guabble is offline
external usenet poster
 
Posts: 2
Default Lots of similar buttons need to call a macro but need to find outwhich button was clicked

Hi

In my spreadsheet I've got about 20 buttons which need to call a
macro, but the macro code needs to be based on the row in which the
button was pressed. Is there a good way of finding out the current
row. Activecell doesn't change when you press the button.

I know I can in each of the click events of the buttons call the macro
and pass in an argument for the row number. Just thought there was a
better way.

I am happy to use labels, autoshapes or buttons if this affects a
suggestion.

Many thanks

Mike