+ Reply to Thread
Results 1 to 5 of 5

PDF Print with ShellExecuteA

  1. #1
    Registered User
    Join Date
    02-25-2024
    Location
    Germany
    MS-Off Ver
    2019
    Posts
    2

    PDF Print with ShellExecuteA

    Hello,

    I need help accessing external PDF files and printing them. I currently have the following workflow:I have to fill out a PDF form with form details and save it as a new PDF. Since I don't (can't) use Acrobat, I have to print the PDF using a PDF printer. With this I want to save the new PDF at a specific location.Almost everything works except saving again.

    I can view or print the PDF.

    - Create and save FDF file
    - Rename FDF file to PDF
    - Open PDF

    But don't print PDF with save without displaying the save dialog. I use PDFX-Change as a PDF printer.With the following code I call up the PDF file for display
    ShellExecuteA 0&, "Open", "c:\Test\Antrag.pdf", vbNullString, vbNullString, SW_SHOWMINNOACTIVE

    or for printing

    ShellExecuteA 0&, "Print", "c:\Test\Antrag.pdf", vbNullString, vbNullString, SW_SHOWMINNOACTIVE

    Can someone help me?


    VG

    Torsten
    Last edited by AliGW; 02-25-2024 at 10:16 AM. Reason: Please do NOT delete posts.

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,853

    Re: PDF Print with ShellExecuteA

    Administrative Note:

    Welcome to the forum.

    We would very much like to help you with your query, however it has been brought to our attention that the same query has been posted on one or more other forums and you have not told us about this. You are required to do so. Cross-posts are allowed but you must provide a link to your posts on other sites.

    Please see Forum Rule #7 about cross-posting and adjust accordingly. Read this to understand why we (and other sites like us) consider this to be important: https://excelguru.ca/a-message-to-forum-cross-posters/

    (Note: this requirement is not optional. As you are new here, I shall do it for you this tome: https://forums.excelguru.ca/threads/...xecutea.11825/)
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Registered User
    Join Date
    02-25-2024
    Location
    Germany
    MS-Off Ver
    2019
    Posts
    2

    1

    Hi,

    Of course you try to find help in several places

    forums.excelguru.ca/threads/print-pdf-with-shellexecutea.11825/#post-49038

    Vg
    Torsten
    Last edited by AliGW; 02-25-2024 at 10:17 AM. Reason: Please do NOT delete posts.

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,853

    Re: PDF Print with ShellExecuteA

    Did you understand that you are required to make these disclosures yourself if you choose to do that?

  5. #5
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,853

    Re: PDF Print with ShellExecuteA

    If you wish to remain a member here, you need to accept and abide by our rules. Offensive comments to ANY member will not be tolerated.

+ 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. ignore margin print area warning when printing from normal print menu
    By nigelog in forum Word Formatting & General
    Replies: 1
    Last Post: 09-21-2018, 05:48 PM
  2. Print until a specified point, print a pdf then print from excel again
    By orkula in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-18-2017, 10:17 AM
  3. Disabled print toolbar and menu but Print Macro button cannot print also...
    By zein97 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-22-2014, 01:42 PM
  4. Set print area of selected range then print preview if ok then print the document!
    By HaroonSid in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-01-2014, 07:10 AM
  5. Print Macro errors on final print command. Run-time error '1004':
    By Steverizer in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-05-2013, 06:41 PM
  6. VBA to set print range, open box asking for print qty, print, then redefine print area
    By galvinpaddy in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 07-11-2012, 06:43 PM
  7. [SOLVED] Pivot Table macro to set print area and print details of drill down data
    By Steve Haskins in forum Excel General
    Replies: 2
    Last Post: 12-28-2005, 01:10 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