LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27
Default Which button did I push

I have two command butons on an Excel page, both assigned
to the same macro. Let's say the function of the macro
is to make the cell to the right of the button blue shade.

How can I tell which button was pushed?

For example:

Sub WhichButton

Select Case ButtonPushed.Top
Case 100
Range("c10").interior.colorindex = 5
Case <=100
Range("c50").interior.colorindex = 5
End Select

End Sub

Thanks
Daniel
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Push button and input box? tripflex Excel Discussion (Misc queries) 2 March 6th 09 03:36 PM
Time with the push of one button Dale G[_2_] New Users to Excel 7 August 6th 08 01:55 PM
Push button paste special? pugsly8422 Excel Discussion (Misc queries) 4 June 7th 06 03:26 PM
push button paste special pugsly8422 Excel Discussion (Misc queries) 2 June 7th 06 02:32 PM
Searching in a row with push on a button Christian R. Excel Programming 0 January 21st 04 07:16 PM


All times are GMT +1. The time now is 04:31 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"