Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Start macro automatic
I want to know how to start a macro automatic. Not when I open Excel but when
I have an Excelfile open. For example: If cell B3=1 then start macro "Start clock" |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Start macro automatic
I suspect you're hinting towards something like:
'============================ Private Sub Worksheet_SelectionChange(ByVal target As Range) If target.Address = "$B$1" And target.Value = 1 Then StartClock End If End Sub ============================ This will have to be put in the code module behind the relevent worksheet (and I think the macro StartClock will need to have its scope extended to Public if it is in a standard module) Hope this helps J BFSWE wrote: I want to know how to start a macro automatic. Not when I open Excel but when I have an Excelfile open. For example: If cell B3=1 then start macro "Start clock" |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Start macro automatic
Hi WhytheQ.
Thank you for the answer. I will try it tomorrow. "WhytheQ" skrev: I suspect you're hinting towards something like: '============================ Private Sub Worksheet_SelectionChange(ByVal target As Range) If target.Address = "$B$1" And target.Value = 1 Then StartClock End If End Sub ============================ This will have to be put in the code module behind the relevent worksheet (and I think the macro StartClock will need to have its scope extended to Public if it is in a standard module) Hope this helps J BFSWE wrote: I want to know how to start a macro automatic. Not when I open Excel but when I have an Excelfile open. For example: If cell B3=1 then start macro "Start clock" |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Automatic start up with Excel? | Excel Discussion (Misc queries) | |||
Automatic start up with Excel? | Excel Discussion (Misc queries) | |||
How to using VBA to automatic start excel application? | Setting up and Configuration of Excel | |||
Help? start macro automatic in excel | Excel Worksheet Functions | |||
Automatic Macro Start | Excel Programming |