The following code is used at the beginning of a Module to make it run every second. It works fine, but it also does the same to any other workbook that is open.
How do I restrict its use to only 1 workbook ("BA - Data.xls")?
How do I restrict its use to only 1 workbook ("BA - Data.xls")?
Code:
dTime = Now + TimeValue("00:00:01")
Application.Workbooks("BA - Data.xls").OnTime dTime, "new_2009"