Results 1 to 3 of 3

Workbook_SheetActivate(ByVal Sh As Object) QUESTION...

Threaded View

HerryMarkowitz Workbook_SheetActivate(ByVal... 08-24-2015, 07:23 AM
Richard Buttrey Re:... 08-24-2015, 07:30 AM
HerryMarkowitz Re:... 08-24-2015, 07:35 AM
  1. #1
    Forum Contributor HerryMarkowitz's Avatar
    Join Date
    09-10-2012
    Location
    Europe
    MS-Off Ver
    Office 2021 - Win10
    Posts
    1,014

    Workbook_SheetActivate(ByVal Sh As Object) QUESTION...

    Hello people,
    1- Copy following code into Sheet1 module.
    Private Sub Worksheet_Activate()
    MsgBox "Hello"
    End Sub
    2- See MessageBox When you click Sheet1.

    3- Copy following code into ThisWorkbook module.
    Private Sub Workbook_SheetActivate(ByVal Sh As Object)
    MsgBox "Hello"
    End Sub
    4-See MessageBox When you click any of sheets.

    Question: How to change above code to work only Sheet1 clicking?
    Last edited by HerryMarkowitz; 08-24-2015 at 07:26 AM.
    Sub DontForgetThese()
         If Your thread includes any code Then Please use code tags...
         If Your thread has been solved Then Please mark as solved...
         If Anybody has helped to you Then Please add reputation...
    End Sub

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Fix an error in MODULE to run Sub Workbook_SheetDeactivate(ByVal Sh As Object)
    By mchilapur in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 07-28-2015, 12:40 PM
  2. [SOLVED] Problem with Workbook_SheetCalculate(ByVal Sh As Object)
    By trimmjens in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-07-2015, 07:47 AM
  3. use "Workbook_SheetDeactivate(ByVal Sh As Object)"
    By elyanivson in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-07-2013, 06:44 AM
  4. Restricting sh.ScrollArea in the Workbook_SheetActivate by windows user login
    By jonvanwyk in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 08-18-2011, 12:14 PM
  5. Workbook_SheetActivate() works but not firing on one worksheet?
    By overflowing in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 02-02-2011, 05:23 PM
  6. Change ByVal Macro Question
    By NewExcelUser in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-17-2008, 03:34 AM
  7. [SOLVED] Workbook_SheetActivate Paste Problem
    By Wayne Cressman in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-04-2006, 08:25 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1