+ Reply to Thread
Results 1 to 4 of 4

VBA to dynamically save a PDF to a new folder based on Inv Number

  1. #1
    Registered User
    Join Date
    01-10-2020
    Location
    London, England
    MS-Off Ver
    MS
    Posts
    2

    VBA to dynamically save a PDF to a new folder based on Inv Number

    I'm pretty new to VBA. I can save a file as a PDF to a path using


    Please Login or Register  to view this content.

    What I want to do within the folder ClientNorthCoast is save the PDF as new folder based upon the client name as I want to put other documents into that folder too so that
    the end folder would be C:Invoicing\ClientNorthCoast\SmithEngineeringLtd\Invoice92.PDF
    But I cannot see how to dynamically introduce a cell reference to the path
    Last edited by Pepe Le Mokko; 01-11-2020 at 03:54 AM.

  2. #2
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,446

    Re: VBA to dynamically save a PDF to a new folder based on Inv Number

    Administrative Note:

    Welcome to the forum.

    We would very much like to help you with your query, however you need to include code tags around your code.

    Please take a moment to add the tags. Posting code between tags makes your code much easier to read and copy for testing, and it also maintains VBA formatting.

    Please see Forum Rule #2 about code tags and adjust accordingly. Click on Edit to open your post, then highlight your code and click the # icon at the top of your post window. More information about these and other tags can be found here

    I did it for you this time. Please read forum rules. Thanks

  3. #3
    Registered User
    Join Date
    01-10-2020
    Location
    London, England
    MS-Off Ver
    MS
    Posts
    2

    Re: VBA to dynamically save a PDF to a new folder based on Inv Number

    Thanks Pepe, hopefully I've put this in the correct format now - sorry for my mistake.

  4. #4
    Forum Expert
    Join Date
    01-23-2013
    Location
    USA
    MS-Off Ver
    Microsoft 365 aka Office 365
    Posts
    3,863

    Re: VBA to dynamically save a PDF to a new folder based on Inv Number

    Hi Sp,

    Try code like the following:
    Please Login or Register  to view this content.
    Lewis

+ 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. [SOLVED] Dynamically count the number of files in a folder
    By 63falcondude in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 03-14-2019, 02:54 PM
  2. Replies: 3
    Last Post: 08-09-2017, 05:09 AM
  3. [SOLVED] Save to folder based on field name?
    By peakoverload in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 05-09-2017, 07:15 AM
  4. [SOLVED] VBA Code to save to a folder within a folder within a folder all based on cell values.
    By sintek in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 07-24-2016, 04:24 PM
  5. [SOLVED] Create a new folder based on a cell name or value and save copy onto that folder
    By Le_Tiago in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 04-20-2012, 01:33 PM
  6. Replies: 6
    Last Post: 08-11-2006, 03:41 PM
  7. save to folder based on cell value
    By Steve in forum Excel General
    Replies: 1
    Last Post: 06-15-2006, 03:00 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