ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   WORKSHEET CHANGE HANDLER (https://www.excelbanter.com/excel-programming/324372-worksheet-change-handler.html)

dan

WORKSHEET CHANGE HANDLER
 
Hello. I want to run a function when a user clicks to view a particular
worksheet. I know a button click event would look like the following:

Sub btnMyButton_Click

End Sub

Is there a change handler that watches when a user goes to a particular
worksheet? If not, is there something similar I can use?

NickHK

WORKSHEET CHANGE HANDLER
 
Dan,
You have
Private Sub Worksheet_Activate()
as an event on each worksheet or
Private Sub Workbook_SheetActivate(ByVal Sh As Object)
as an event on ThisWorknook

NickHK

"Dan" wrote in message
...
Hello. I want to run a function when a user clicks to view a particular
worksheet. I know a button click event would look like the following:

Sub btnMyButton_Click

End Sub

Is there a change handler that watches when a user goes to a particular
worksheet? If not, is there something similar I can use?





All times are GMT +1. The time now is 11:28 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com