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: 34
Default Worksheet selection change (running marco when cell selected)

Hi,

I want to be able to navigate around my sheet by running macro's when
certain cells are selected. I have the following code;


Private Sub Worksheet_SelectionChange(ByVal Target As Excel.Range)
If Not Intersect(Target, Range("A49")) Is Nothing Then
showcalendar
End Sub

which works fine, however I have tried numerous ways to have this code
operate based on different cells.
Eg. I also want to run a macro when cell AF95 is selected and a
different macro when cell A53 is selected.

I cannot find a way to use this code more than once. Any help is
appreciated.

Thanks,

 
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
Running a macro from currently selected cell? GD Excel Discussion (Misc queries) 1 February 10th 09 05:11 PM
specify cell selection in a marco chubach Excel Discussion (Misc queries) 3 February 8th 07 11:47 PM
Running a macro in a selected cell... Steve Excel Discussion (Misc queries) 2 January 19th 06 10:58 PM
Running code on a drop down selection change Steve Haack Excel Worksheet Functions 1 April 26th 05 05:03 AM
Saving copied info while running a Selection Change Macro J Streger Excel Programming 1 April 5th 05 12:33 AM


All times are GMT +1. The time now is 07:15 PM.

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"