+ Reply to Thread
Results 1 to 3 of 3

Macro Definitions - File Name Changes from Master Templates

  1. #1
    Registered User
    Join Date
    04-10-2014
    Location
    London
    MS-Off Ver
    Office 2010
    Posts
    4

    Macro Definitions - File Name Changes from Master Templates

    Hi All

    I am hoping someone will be able to help.

    I am currently working on a performance document. I am working on the principle of having a master template which people can then access, Save As, and use to monitor performance around KPI’s.

    The issue I am having is around the name of the document changing when it is saved as, as all records have to retained. The macro I am struggling with is designed to unlock the workbook & worksheet, copy the worksheet specified into a new workbook and then return to the workbook the macro is held within and lock it back up. However, when the name changes it just locks the new workbook rather that the version I am asking it to.

    ActiveWorkbook.Unprotect Password:="KPIreview"
    ActiveSheet.Unprotect Password:="KPIreview"
    Sheets("EID Graphs").Select
    Sheets("EID Graphs").Copy
    Windows( _
    "Kent - Monthly Activity & Performance Review - Version 17 - Master.xlsm" _
    ).Activate
    ActiveSheet.Protect Password:="KPIreview", DrawingObjects:=True, Contents:=True, Scenarios:=True
    ActiveWorkbook.Protect Password:="KPIreview", Structure:=True, Windows:=False


    Is there anyway I can change the “Kent – Monthly Activity & Performance Review – Version 17 – Master.xlsm” statement within the macro to reflect the change in name of the document?

    Thank you in advance for any help you can provide.

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Macro Definitions - File Name Changes from Master Templates

    Duplicate post.
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Registered User
    Join Date
    04-10-2014
    Location
    London
    MS-Off Ver
    Office 2010
    Posts
    4

    Re: Macro Definitions - File Name Changes from Master Templates

    Hi SHG

    Has this already been asked somewhere else then?

    Do you happen to know what the title was so I could review the responses?

    Many Thanks
    BWS

+ 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. Macro Definitions - File Name Changes from Master Templates
    By bwsutton in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-10-2014, 11:32 AM
  2. Macro to full in data from Master file to a daily recon file
    By Dnels in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 08-21-2013, 12:03 PM
  3. Replies: 0
    Last Post: 03-04-2013, 03:40 AM
  4. [SOLVED] Macro - Master file to import data from another open file with variable file name
    By jdodz in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 12-10-2012, 10:56 PM
  5. [SOLVED] Macro to copy file names and data from each file in a folder into master spreadsheet
    By dee1989 in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 07-10-2012, 05:52 AM

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