+ Reply to Thread
Results 1 to 2 of 2

Macro To Save As PDF

  1. #1
    Registered User
    Join Date
    02-27-2014
    Location
    London
    MS-Off Ver
    Excel 2007
    Posts
    25

    Macro To Save As PDF

    Hi all,

    First Post.

    I want to save an excel document as a PDF based on a cell reference.

    The cell reference is B14 and this is

    ChDir "U:\Jam\Harris\Quotations"
    ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, Filename:= _
    "U:\Jam\Harris\Quotations\&Text(B14).pdf", Quality:=xlQualityStandard, _
    IncludeDocProperties:=True, IgnorePrintAreas:=False, OpenAfterPublish:= _
    False

    That was the closest i could get when typing it out.

    Any help would be great!

  2. #2
    Forum Expert Alf's Avatar
    Join Date
    03-13-2004
    Location
    Gothenburg/Mullsjoe, Sweden
    MS-Off Ver
    Excel 2019 and not sure I like it
    Posts
    4,758

    Re: Macro To Save As PDF

    You could try the setting the value in B14 to U:\Jam\Harris\Quotations\ i.e. no quotation marks just the name string and then use a line like this in VBA.

    Please Login or Register  to view this content.
    Alf

+ 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. how to specify a file save path to a save macro
    By Solidstan in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 10-04-2013, 05:33 PM
  2. Macro to disable SAVE and SAVE AS
    By Charmymay in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 02-04-2013, 10:06 AM
  3. Macro with cell reference as a name, but prompt for save location and save as csv
    By tomham in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-15-2012, 06:21 PM
  4. [SOLVED] Macro to save sheets as different workbooks on save
    By BridgeCat in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-09-2012, 08:10 AM
  5. where can i find macro codes for various functions such print, save and save as
    By fellayaboy in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-23-2011, 02:06 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