Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
I wish to run a macro after clicking into various cells.
I have 10 different macros and 10 cells with names of these macors and I wish to run the relevant macro when I click into the cell. ie. A1 content = "Scores" and when I click into that cell, I wish the "Scores" macro to run. Can this be done? If so, how? TIA Esra |
#2
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Easily done but give us all the detail and the code. There is probably an
easier way. -- Don Guillett Microsoft MVP Excel SalesAid Software "Esradekan" wrote in message ... I wish to run a macro after clicking into various cells. I have 10 different macros and 10 cells with names of these macors and I wish to run the relevant macro when I click into the cell. ie. A1 content = "Scores" and when I click into that cell, I wish the "Scores" macro to run. Can this be done? If so, how? TIA Esra |
#3
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
I have a master grid of Sports Teams (Aussie Rules), that the macros
copy and paste from the team sheets so I can see at a glance the team home and away status, game results etc. ie. If i want to view the Adelaide team stats, and game results etc, i wish to copy from the team page those stats, simple copy/paste macro (AdelaideScores). If I want Brisbane stats, I click into the Cell with Brisbane in it, and run the macro BrisbaneScores. Makes it easier for team comparisons. I already have the copy/paste macros done, (ie AdelaideScores, BrisbaneScores etc) and the grid where the macros paste, just would rather do it by clicking in the team cell, than assigning the macro to an object. Its tidier. Does that make sense? Hope so TIA for help Esra On Wed, 26 Mar 2008 17:39:53 -0500, "Don Guillett" wrote: Easily done but give us all the detail and the code. There is probably an easier way. |
#5
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Sent him this to replace a bunch of very long macros.
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean) If Not Intersect(Target, Range("L6:L21")) Is Nothing Then mysht = Application.Substitute(target, " ", "") Range("m2") = Target Range("m6:x21").Value = _ Sheets(mysht).Range("c6:n21").Value End If End Sub -- Don Guillett Microsoft MVP Excel SalesAid Software "Don Guillett" wrote in message ... You really didn't give enough info but you could probably use a double_click event from the sheet module or even a drop down list. Send the workbook to my address below if you would like me to take a look at making this better. -- Don Guillett Microsoft MVP Excel SalesAid Software "Esradekan" wrote in message ... I have a master grid of Sports Teams (Aussie Rules), that the macros copy and paste from the team sheets so I can see at a glance the team home and away status, game results etc. ie. If i want to view the Adelaide team stats, and game results etc, i wish to copy from the team page those stats, simple copy/paste macro (AdelaideScores). If I want Brisbane stats, I click into the Cell with Brisbane in it, and run the macro BrisbaneScores. Makes it easier for team comparisons. I already have the copy/paste macros done, (ie AdelaideScores, BrisbaneScores etc) and the grid where the macros paste, just would rather do it by clicking in the team cell, than assigning the macro to an object. Its tidier. Does that make sense? Hope so TIA for help Esra On Wed, 26 Mar 2008 17:39:53 -0500, "Don Guillett" wrote: Easily done but give us all the detail and the code. There is probably an easier way. |
#6
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Thanks Don, your a legend, over and above what I asked, problem
sorted. I bow to your wisdom. Esra On Wed, 26 Mar 2008 18:13:53 -0500, "Don Guillett" wrote: You really didn't give enough info but you could probably use a double_click event from the sheet module or even a drop down list. Send the workbook to my address below if you would like me to take a look at making this better. |
#7
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Glad to be of help
-- Don Guillett Microsoft MVP Excel SalesAid Software "Esra Dekan" wrote in message ... Thanks Don, your a legend, over and above what I asked, problem sorted. I bow to your wisdom. Esra On Wed, 26 Mar 2008 18:13:53 -0500, "Don Guillett" wrote: You really didn't give enough info but you could probably use a double_click event from the sheet module or even a drop down list. Send the workbook to my address below if you would like me to take a look at making this better. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Problems Clicking on a Cell | Excel Discussion (Misc queries) | |||
after clicking on a cell cannot get out of worksheet | Excel Discussion (Misc queries) | |||
Using Macro to sort without clicking on macro button | Excel Discussion (Misc queries) | |||
Colour by clicking cell | New Users to Excel | |||
Run macro from clicking on a cell | Excel Discussion (Misc queries) |