+ Reply to Thread
Results 1 to 2 of 2

Saving a specific sheet from workbook and leaving only one specific module in it.

  1. #1
    Registered User
    Join Date
    04-18-2019
    Location
    Ireland
    MS-Off Ver
    2019
    Posts
    3

    Saving a specific sheet from workbook and leaving only one specific module in it.

    I would like to to ask if its possible to save a macro-enabled specific sheet from a workbook and to leave that saved file with only a specific module on my choice.

    For example:
    My original workbook will have for example 10 modules all containing lots of different VBA.
    However, I want it to save a specific sheet through a sub, lets call that new sheet X-Sheet - a separate macro-enabled file.
    At the same time this X-Sheet must have inside of it only one module on my choice.
    I want that module to be accessible from anywhere so if I send/email this new one sheet macro-enabled Excell file to someone - they should be able to use subs and functions from there without them needing to have access to my workbook file with 10 modules. I mean they should have only the X-Sheet on the computer - not the original workbook for it to work.

    I know this can be done manually but it would make it very repetitive as my project will require that to be done very often.

    Summary:
    I have 10 modules
    I need to press a button (sub)
    This sub will save a specific sheet from my workbook as a macro-enabled-excell-file
    This separate file will have to have 9 of the original modules removed but to have 1 of the modules on my choice inside of it.
    This would allow the end user to which I will send this file to be able to have the working buttons and functions but he won't have access to things that he/she should not see or alter (those 9 modules should be deleted from this new file).
    Last edited by 6StringJazzer; 07-05-2019 at 03:54 PM. Reason: Moved from Excel General

  2. #2
    Forum Expert
    Join Date
    11-24-2013
    Location
    Paris, France
    MS-Off Ver
    Excel 2003 / 2010
    Posts
    9,831

    Lightbulb


    The easy way is to move the module code to the worksheet module so when the sheet is copied
    only its code follows in the new workbook and there is nothing specific to code …

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Saving a Workbook With A Specific File Name in a Specific Location
    By kyjae in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-06-2016, 02:49 PM
  2. Saving specific Sheet as CSV in the current location of the workbook
    By saif87 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-14-2016, 07:00 AM
  3. Saving a specific range into a new workbook
    By Student1990 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 11-15-2013, 07:20 AM
  4. saving to a specific file as workbook is update
    By superchew in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 09-09-2013, 06:22 AM
  5. Macro to exit all workbook leaving one specific workbook open
    By Khanzaki in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-22-2013, 05:09 AM
  6. Excel 2007 : saving advanced options to specific workbook
    By Shadowmistress in forum Excel General
    Replies: 2
    Last Post: 05-06-2010, 12:06 PM
  7. Assigning Macro/Module to specific sheet
    By JOGIER in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-28-2009, 03:35 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