+ Reply to Thread
Results 1 to 2 of 2

Remove all code from workbook except "Thisworkbook"

  1. #1
    Valued Forum Contributor realniceguy5000's Avatar
    Join Date
    03-20-2008
    Location
    Fl
    MS-Off Ver
    Excel 2003 & 2010
    Posts
    951

    Remove all code from workbook except "Thisworkbook"

    Hi Everyone,

    I have a small problem hoping someone may know a work around. I have used this code to delete all the code in a workbook and it has worked rather well. However now I want to delete all the code except the code in "ThisWorkbook" Can someone advise?


    Please Login or Register  to view this content.

    Thank You, Mike

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,464

    Re: Remove all code from workbook except "Thisworkbook"

    In the loop where you remove the code, check for .vbcomponents(i).Name = "ThisWorkbook"

    Regards
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


+ 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