+ Reply to Thread
Results 1 to 3 of 3

how to keep workbook name active

  1. #1
    Registered User
    Join Date
    06-01-2006
    Posts
    19

    how to keep workbook name active

    I created a macro that permits a user to open an existing workbook (say VersionOne) and copy their data into a new version (versionTwo).

    Please Login or Register  to view this content.
    The macro is becoming quite large and I want to create several additional macros to help me keep track of each worksheet being copied. Is there a way for the name "VersionOne" to stay active from one marco to the next? I don't want the user to keep opening up the same workbook. Thanks
    Last edited by grantj; 03-25-2009 at 01:37 PM.

  2. #2
    Forum Expert
    Join Date
    01-15-2007
    Location
    Brisbane, Australia
    MS-Off Ver
    2007
    Posts
    6,591

    Re: how to keep workbook name active

    Hi

    Some options..

    1) Create a global variable that is valid across all the macros in the project
    2) Create a storage point on say the spreadsheet containing the macro
    3) Pass the current name as an argument to the subsequent macros
    4) Make the variable static
    5) Put the variable value into a text file
    6) Use Savesetting / Getsetting to store / retrieve values from the registry.....


    HTH

    rylo
    Last edited by rylo; 03-24-2009 at 02:19 AM.

  3. #3
    Valued Forum Contributor mudraker's Avatar
    Join Date
    11-10-2003
    Location
    Melbourne, Australia
    Posts
    3,983

    Re: how to keep workbook name active

    grantj

    Please take a couple of minutes and read ALL theForum Rules then wrap your VBA code (Rule 3)
    Please Read Forum Rules Before Posting
    Wrap VBA code by selecting the code and clicking the # icon or Read This
    How To Cross Post politely

    Top Excel links for beginners to Experts

    If you are pleased with a member's answer then use the Scales icon to rate it
    If my reply has assisted or failed to assist you I welcome your Feedback.

+ 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