+ Reply to Thread
Results 1 to 3 of 3

Macro to comment block other macros/subs

  1. #1
    Forum Contributor
    Join Date
    07-22-2009
    Location
    USA
    MS-Off Ver
    Excel 2003
    Posts
    122

    Macro to comment block other macros/subs

    I have a macro that i use for editting, which unhides rows and columns, and resizes rows. A problem that i run into is that there are other macros/subs on the worksheet change event that will run, and render the macro useless and has to be rerun again. Is it possible to include a line or multple lines to comment block out another macro sub, then when the apposing macro is run the hide everything, uncomment block it?
    Last edited by paxile2k; 05-13-2011 at 12:02 PM.

  2. #2
    Forum Guru romperstomper's Avatar
    Join Date
    11-04-2008
    Location
    A1
    MS-Off Ver
    Most
    Posts
    12,302

    Re: Macro to comment block other macros/subs

    It sounds to me as though you want Application.Enableevents to prevent the worksheet_change macros from running when your macro is called.
    Remember what the dormouse said
    Feed your head

  3. #3
    Forum Expert davegugg's Avatar
    Join Date
    12-18-2008
    Location
    WI, US
    MS-Off Ver
    2010
    Posts
    1,884

    Re: Macro to comment block other macros/subs

    I think you could try:

    Please Login or Register  to view this content.
    Just make sure to turn them back on when you are finished!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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