+ Reply to Thread
Results 1 to 8 of 8

Need macro so file only saved with new name

  1. #1
    Forum Contributor
    Join Date
    07-02-2012
    Location
    Florida
    MS-Off Ver
    Home -Excel 2007, Work 2016
    Posts
    254

    Need macro so file only saved with new name

    No sample attached as the file contains no macros.
    File name is "Master if only one invoice",
    If any data entered, don't want user to be able to save it without changing the name.
    Believe it would require some kind of code so I could save file if changes require.
    Thank you!!
    Last edited by ILoveStMartin; 05-30-2020 at 04:18 PM.

  2. #2
    Forum Expert dangelor's Avatar
    Join Date
    09-06-2011
    Location
    Indiana, USA
    MS-Off Ver
    365 Pro Plus
    Posts
    2,274

    Re: Need macro so file only saved with new name

    Possibly with...
    Please Login or Register  to view this content.
    ...placed in the worksheet's code module.
    Last edited by dangelor; 05-30-2020 at 06:04 PM.

  3. #3
    Forum Contributor
    Join Date
    07-02-2012
    Location
    Florida
    MS-Off Ver
    Home -Excel 2007, Work 2016
    Posts
    254

    Re: Need macro so file only saved with new name

    Super!!!!
    You came at it from a different angle than I had in my mind but it will work just as well.
    Question, if I see that some basic change to the file is needed, how would I get in to do that?
    Thanks!!

  4. #4
    Forum Expert dangelor's Avatar
    Join Date
    09-06-2011
    Location
    Indiana, USA
    MS-Off Ver
    365 Pro Plus
    Posts
    2,274

    Re: Need macro so file only saved with new name

    Easiest would be to edit the name in the code to something else and change it back when you're done. Second easiest would be to save the file as a different name, and change it back when you're done.

  5. #5
    Forum Contributor
    Join Date
    07-02-2012
    Location
    Florida
    MS-Off Ver
    Home -Excel 2007, Work 2016
    Posts
    254

    Re: Need macro so file only saved with new name

    Put it to the test - Selected Save - Got this (with name I changed the file to)
    "Single Invoice -Must be saved in job folder.xlsm already exists. Do you want to replace it.", so it could be saved and the original lost.
    Is there a way around that potential problem??
    Also - when doing the save I realized I do not want it saved unless all needed cells have been filled in. I can set it so F14 will contain an "OK" when key cells have been filled in.
    Do I need to go back and restate my need or enter a new post?
    Thanks - Appreciate your help!!

  6. #6
    Forum Expert mikerickson's Avatar
    Join Date
    03-30-2007
    Location
    Davis CA
    MS-Off Ver
    Excel 2011
    Posts
    6,229

    Re: Need macro so file only saved with new name

    Have you considered saving the Master book as a template? That file will be Master.xltx
    When the user opens it and uses it, they will have to save it as a workbook. Even if it has the same name, it will have a different extension (.xlsx)
    _
    ...How to Cross-post politely...
    ..Wrap code by selecting the code and clicking the # or read this. Thank you.

  7. #7
    Forum Expert dangelor's Avatar
    Join Date
    09-06-2011
    Location
    Indiana, USA
    MS-Off Ver
    365 Pro Plus
    Posts
    2,274

    Re: Need macro so file only saved with new name

    To attempt what you ask will require a workbook. See the yellow banner above: HOW TO ATTACH YOUR SAMPLE WORKBOOK

  8. #8
    Forum Contributor
    Join Date
    07-02-2012
    Location
    Florida
    MS-Off Ver
    Home -Excel 2007, Work 2016
    Posts
    254

    Re: Need macro so file only saved with new name

    Thanks - buy why the Cross post link?? (Did not see it the first time I read your reply)
    I am guessing that what triggered it was my "Oh - just saw something I should have included int my original post."
    But I do not see the connection!

+ 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. Block usage of master file unless it has been saved into another folder
    By ILoveStMartin in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-26-2020, 06:54 AM
  2. Open the last saved file paste in master file"
    By Mohan Chalageri in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 02-03-2020, 02:39 AM
  3. When file saved with name other than Master, need instructional text on sheet to go away
    By ILoveStMartin in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-23-2019, 02:03 PM
  4. [SOLVED] Force cells to be filled before file can be saved
    By dw_22801 in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 02-07-2019, 06:28 PM
  5. 4folders, 4files (file names change weekly) merge into one master file, as needed
    By alkangirl in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-01-2012, 08:28 PM
  6. One Master File that will be cut rows and saved into numerous files
    By asian_xl in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 12-31-2009, 12:22 AM
  7. [SOLVED] To get client data from a saved file back to the master file
    By Darmac54 in forum Excel General
    Replies: 0
    Last Post: 08-17-2005, 11:05 PM

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