+ Reply to Thread
Results 1 to 4 of 4

Saving a file to two directories

  1. #1
    Forum Contributor
    Join Date
    07-30-2012
    Location
    Leeds
    MS-Off Ver
    Excel 2013
    Posts
    177

    Saving a file to two directories

    Hi all,
    I am in the final stages of a wb for setting cover for teachers at my school.

    I have set up the vba for applying the correct header (based on selections in the 'menu' sheet). This vba needs to run before any vba for the actions below.
    Please Login or Register  to view this content.
    I need the wb to do the following on a button click:
    - Save a copy to a directory saved in the sheet 'drive' cell B1 as an excel file
    - Save a PDF version to the directory in sheet 'drive' cell B2.

    wb attached. Thank you in advance! Luke
    Attached Files Attached Files

  2. #2
    Forum Contributor
    Join Date
    07-30-2012
    Location
    Leeds
    MS-Off Ver
    Excel 2013
    Posts
    177

    Re: Saving a file to two directories

    Apologies all I'm unable to edit the original post.

    The filename for saving both files is in sheet 'Drive' cell B1

    I need the PDF version to only save sheets P1,P2,P3,P4,P5,EEP - IF they have a YES in cell E1, but in one PDF document. I have this:
    Please Login or Register  to view this content.
    but I cannot figure out how to get my filename and directory in there, or how to get it to only merge sheets with YES in cell E1

  3. #3
    Forum Guru
    Join Date
    07-25-2011
    Location
    Florida
    MS-Off Ver
    Excel 2003
    Posts
    9,643

    Re: Saving a file to two directories

    Please Login or Register  to view this content.
    Last edited by AlphaFrog; 04-27-2013 at 02:55 PM.

  4. #4
    Forum Contributor
    Join Date
    07-30-2012
    Location
    Leeds
    MS-Off Ver
    Excel 2013
    Posts
    177

    Re: Saving a file to two directories

    Hi Alpha dog,
    Many thanks for the code, it's working in the main parts. I just need to check some of the following:
    - It is autosaving a file to the directory, but not as a .xls etc, just as a file without extension. However it is asking if changes to Book1 need saving, and if you do save it it correctly saves only the sheets set to yes.
    - The vba is opening the print dialog before running, which on my test was loading onenote, is it possible to stop this?
    - What vba would be needed to format the center header as TW Cen, Bold Size 16?

    Updated wb: Cover Work v16.xlsm

    Many thanks!

    Luke

+ 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