Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run macro when worksheet is opened
I'm trying to get a macro (named Refresh) to run whenever a worksheet is
opened. I've tried using Private Sub Worksheet_Activate() Refresh End Sub as was suggested in other posts, but this doesn't seem to work. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run macro when worksheet is opened
And this macro is placed in the worksheet? In other words, right-click the
worksheet tab and hit View--Code, and you can see it there? Also, what is it you're trying to refresh? ******************* ~Anne Troy www.OfficeArticles.com www.MyExpertsOnline.com "MLT" wrote in message ... I'm trying to get a macro (named Refresh) to run whenever a worksheet is opened. I've tried using Private Sub Worksheet_Activate() Refresh End Sub as was suggested in other posts, but this doesn't seem to work. |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run macro when worksheet is opened
The macro is in the worksheet. It runs a query that pulls in data from an
Access database. The macro itself works fine if I run it manually. |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run macro when worksheet is opened
Nevermind, I figured it out. Since this was the only worksheet, I should
have used Workbook_Open() instead of Worksheet_Activate(). |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Protect Excel Worksheet to be opened on one PC only | Excel Discussion (Misc queries) | |||
Go to cell with maximum value when worksheet opened | Excel Discussion (Misc queries) | |||
how to get a cell to only update when worksheet is opened? | Excel Discussion (Misc queries) | |||
Add-In will not allow worksheet to be opened. | Excel Programming | |||
Sql query on a range in the opened worksheet | Excel Programming |