Results 1 to 4 of 4

Limiting a Macro applied to only 1 worksheet in a file

Threaded View

  1. #1
    Registered User
    Join Date
    02-05-2022
    Location
    Framingham, MA
    MS-Off Ver
    365
    Posts
    3

    Limiting a Macro applied to only 1 worksheet in a file

    This script works well for my need, hiding specific columns, unfortunately it also hides columns in other worksheets in the same file. can anyone help me keep the macro focused on only one worksheet? The Sheet name i need it to work on is called "Member Data"

    Sub UNCheck_Hide_Columns()
            
        Dim sh As Worksheet
        Application.ScreenUpdating = False
        
        For Each sh In Sheets
            On Error Resume Next
            sh.CheckBoxes.Value = False
            On Error GoTo 0
        Next
    Last edited by AliGW; 11-27-2023 at 11:33 AM. Reason: Code tags added - please review the forum guidelines.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Can DrawingObjects:=False be applied to a range instead of the entire worksheet?
    By Royzer in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-12-2017, 12:19 PM
  2. limiting the number of users in an Excel worksheet at a time
    By katkth7533 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-30-2015, 12:45 PM
  3. Beforesave code applied to any file
    By sparent27 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 12-01-2014, 09:52 PM
  4. [SOLVED] Save file as CSV from XLS after VBA applied
    By djfscouse in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-05-2013, 05:10 PM
  5. Multi-Worksheet results needed with Rules applied
    By vortexkid in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 03-21-2012, 08:22 PM
  6. Limiting worksheet access through passwords
    By tvwhome in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 06-22-2010, 03:52 PM
  7. [SOLVED] Can changes to a worksheet be applied to all wksheets in wkbook?
    By SandyM in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 09-18-2005, 02:05 PM

Tags for this Thread

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