Printing PDF file Using Shell Command Line

Hello I am writing  a program from MicroSoft Excel's Macro that will print PDF files. I have managed to get the program to work but I cannot prevent the file not being opened. Basically the PDF file would get printed but the file would automatically opened up.
I am using shell command line to write this. And this is my code:
FileName = "C:\EGB Gaming Lab\Training Manual\Testing Documents\Testing Checklists\Bill Validator*"
myShell.Run ("Acrobat.exe /t" & FileName)
I have tried using /h but it still opens the file.
I am referring to this support case:
http://support.adobe.com/devsup/devsup.nsf/docs/52080.htm
Thank you

You may be able to adopt this script:
on open dropped_items
   -- Write a message into the event log.
   log "  --- Starting on " & ((current date) as string) & " --- "
   -- set see to alias "Macintosh-HD:Users:mac:Desktop:app.html"
   -- set dropped_items to {see}
   set the_app to "Safari"
   repeat with dropped_item_ref in dropped_items
      --set UrlBase to "xzzx FILE://" & POSIX path of dropped_item_ref
      --display dialog UrlBase
      -- Activate
      activate application the_app
      -- Open the URL 
      tell application the_app
         open dropped_item_ref
         -- print dropped_item_ref
         tell application "System Events"
            tell process the_app
               delay 3
               -- click menu item "Print..." of menu "File" of menu bar 1
               keystroke "p" using command down
               delay 1
               keystroke return
               delay 10
               keystroke "w" using command down
            end tell
         end tell
         --quit
      end tell
   end repeat
end open

Similar Messages

  • Print PDF file using Acrobat SDK - Warning message

    Hello,
    We are trying to create automatic program in c# that will print all pdf files located in a specific folder, using Adobe Acrobat 9.0 SDK.
    Whenever the application tries to print file, we receive a warning message ("WARNING! A script has requested to print an Acrobat file. This could print an entire document. Do you want to proceed printing?").
    If we press yes, the file is printed, but next time we'll run the application, this message will appear again.
    Since this application supposed to run automatically (with no interaction with the end users), we want to prevent this warning message from appearing.
    How can we eliminate this warning message?
    Is there any other way to print PDF files using Adobe Acrobat from another application?
    Thanks,
    Lilach.

    joeln3:  I believe the original post refers to a client application, not a web page.  Why use JavaScript from within a client application?  I understood their use case to involve a client app referencing the PDF Library, loading various PDF files, and using one (or more) of the PDF Library's Print methods to invoke Acrobat's internal print routines.
    Dave

  • Cannot print pdf file using windows 7 64 bit and trial acrobat X

    cannot print pdf files using trial version of Acrobat X and windows 7 64 bit prints all other files no problem.
    I've done some searching but can't find anything that helps
    Thanks for any help
    Kim

    I fixed this problem. I had to turn off the browser virtualization feature in Zone Alarm Extreme Security. This wiped out all of the Firefox settings, but I had bookmarks, etc. backed up. (answered by original poster)

  • Unable to print PDF files using Acrobat 8.

    I had to uninstall and then reinstall Office for Mac 2011.  I don't know if it's related or not,  but since doing so I have been unable to print PDF files using Adobe Acrobat 8. After opening a PDF file and hitting print, Adobe Acrobat 8 crashes. Any suggestions?  I already uninstalled and reinstalled Adobe Acrobat 8, but it still won't print PDF files. O

    While you are having difficulty in printing a PDF file, you may try the  subsequent steps. If you are in a rush and would like to print a simple  document such as a letter, a form, or a calendar, you may print it as an  image. Next option is that you may need to update your printer driver   if the PDF does not print, the PDF prints as a blank page or with  unreadable text or if you get an error message when you print.  Sometimes, when you print a file that is on a thumb drive or a network,  the file gets damaged. Then you have to open the copy on your hard drive  and print again. At last, you can try printing the PDF using another  printer and check your printer connection too if the PDF does not get  printed. get more help to fix unable to printer PDF file hope this helps you.
    Good Luck!

  • How to print PDF files using java print API

    Hi,
    I was goign throw lot of discusion and reading lot of forums related to print pdf files using java api. but nothing seems to be working for me. Can any one tell me how to print pdf files using java api.
    Thanks in advance

    Mike,
    Can't seem to get hold of the example described in your reply below. If you could let us have the URL to get then it would be great.
    My GUI application creates a pdf document which I need to print. I want to achieve this using the standard Java class PrinterJob (no 3rd party APIs I'm afraid, commercial restraints etc ..). I had a stab at it using the following code. When executed I get the pretty printer dialog then when I click ok to print, nothing happens!
    boolean showPrintDialog=true;
    PrinterJob printJob = PrinterJob.getPrinterJob ();
    printJob.setJobName ("Contract.pdf");
    try {
    if (showPrintDialog) {
    if (printJob.printDialog()) {
    printJob.print();
    else
    printJob.print ();
    } catch (Exception PrintException) {
                   PrintException.printStackTrace();
    Thank you and a happy new year.
    Cheers,
    Chris

  • How to print Pdf files using Adobe Reader

    How to print Pdf files using Adobe Reader

    Open the PDF file with File > Open... in Adobe Reader and print it with File > Print

  • Creating .swf from .fla file using ADT command line

    Dear Adobe Community and Moderators:
    Is it possible to use the ADT command line to directly compile an .fla file into an .swf file? Context: I have an app created in Flash Pro CS55 (6 months worth of work), but now found Adobe has dropped Flash Pro in favor of Flash Builder or Flex. I have some native extensions I want to use for iOS, but they require Air 3.1 to compile (swf-version=14) i.e. using the MessageUI framework in a static .a library for an Air app. Flash Pro CS55's top end limit seems to be swf-version=13 (Flash 11). Because of heavy investment in time and energy into our Air app in Flash Pro, it's not feasible to convert to Flex by end of week. I tried creating an .swc file, and taking the library.swf from that, but alas, a catch-22, Flash Pro CS55 only compiles to swf-version=13.
    Is there any way to either (a) directly compile my root .swf file (from the .fla file) using a command line (so I can use ADT from Air 3.1 SDK) or (b) some way I can marry a native extension I've found I can use on GitHub which is swf-version=14? Again, my issue is that I have to use Air 3.1 since only it supports iOS5.
    Any thoughts, suggestions, comments are highly appreciated (including if it's not possible to do what I'm trying to do).
    Thank you Adobe community in advance,
    Alex

    I have the exact same question, please respond if you hold the answer to this! mxmlc won't work for me since I have created too many assets within the fla already! Thanks!

  • Windows Service no longer able to print PDF files using Adobe Reader 11.0.07.79

    We have a Windows Service that watches a folder for PDF files to be deposited.  Once awakened, it executes the Adobe Reader in command line mode to print the PDF files to secure check printers. The Windows Service was working fine with 11.0.06.70 but no longer works with 11.0.07.79.
    There are no event viewer errors or errors returned to our Process.Start() call.  The Windows Service is running under the identify of an administrator account and has explicit full access to the printer.  We have also tried the local computer's Administrator account as well as the default Local Service, but none work.
    Using ProcMon to examine the failure, it showed Adobe Reader making many successful registry and file accesses.  Adobe Reader then creates a new process, another instance of itself to read in the PDF file and print to the printer.  However, ProcMon only shows Adobe Reader accessing AcroRd32.exe, syswow.dll (sp) and ntdll.dll and then the thread and process immediately exits with an exit code of 0 (no file or registry accesses).  So, something is causing the instantiated process to fail immediately.
    After more research and trying many things, we disabled "Enable Protected Mode at Startup".  This enabled things to work again.
    We are concerned that disabling this feature might expose security concerns for our customers.
    We are suspecting that some security concerns were tightened with 11.0.07.79 that has inadvertently caused printing from Windows Services to falsely be identified as security violations.  Can you please investigate and provide a resolution?
    Thank you.
    Craig Keating
    Alliance Enterprises, Inc.
    [email protected]

    Hi,
    Can you please give the following details:
    1) Command (given in command line)used to print PDF files?
    2) Is the issue reproducible with other printers as well?
    3) Is directly printing the PDF from that folder using command line i.e without using windows service works fine or not?
    Thanks,
    Shakti K

  • Laserjet p2055dn is slow printing pdf files using mac

    My Mac is very slow printing pdf files on my hp laserjet p2055dn.  I have noticed fixes for this problem for people using Windows.  Is there a Mac solution?

    Do you want to create PDF files using Java? If so, there is a library available at http://www.lowagie.com/iText/docs.html Check out this site. There are many more similar PDFGEnerator tools that you can use..

  • Printing Pdf files using coldfusion

    my visitors need to print pdf files from my web site
    but they want to print with open the acrobat reader
    someone knows how to do it ?
    Rene marquez

    Also <cfreport format="PDF"...
    See
    http://livedocs.adobe.com/coldfusion/7/htmldocs/00001466.htm

  • Printing PDF files using java

    Is there a class or utility that already does this?
    Thx in advance.

    Do you want to create PDF files using Java? If so, there is a library available at http://www.lowagie.com/iText/docs.html Check out this site. There are many more similar PDFGEnerator tools that you can use..

  • I can't print PDF files using Firefox on my MAC I tried the suggested help PDF files are blank and can't be downloaded on MAC whic is my problem

    I can't print "Living Social" vouchers, financial statements that are in a PDF format

    There have been problems reported with the latest Adobe Reader update on Mac.<br />
    See [[/questions/925119]]
    You can disable the Adobe Reader plugin in Firefox and use the Adobe Reader program or Preview instead.
    *Firefox > Preferences > Applications > Adobe PDF document : Use Adobe Reader
    PDF files may also be found under another entry like Portable document.

  • Printing pdf files using windows 8

    I have recently installed windows 8 on my home computer and when I tried to print some pdf files (like taxes) all I get is a preview no command to actually print.

    http://exportpdf.adobe.com
    Message was edited by: Test Screen Name

  • Printing PDF file using lp gives garbage output

    Hi,
    We have an HP printer which was working fine till last week, printing everything. Now, the normal text file prints are printing fine, but when a PDF document is sent for printing the output is kind of garbage with strange characters and isnt what it should be printing. Printing had and is being done using normal lp command. Has anyone faced any similar problem? and if so, what is the solution? Thanks.
    Raza

    hi there.
    i'm facing the same problem i can't find anything that could print my pdf...
    maybe u found smth??

  • Abobe 9: Printing a PDF file using a DOS command

    I have Adobe 9.4.0 on a server and would like to print PDF files using a DOS command. The DOS command we are using is:
    start Acrord32.exe /T/S/h/O "C:\BO_Archival_Code_Deployment\Print\TINF018_C.pdf" "Lexmark T644 PS3 - 10.192.36.126"
    With this, we are able to print only page 1 of the PDF file. The other pages remain unprinted. This means there is no issue related to printer configuration, firewalls, etc.
    Other observations:
    1) When we print the file manually after opening it in Adobe 9.4.0, all pages are printed.
    2) We found that the above command provides different results with Adobe 8.2.6 i.e. with the DOS command, all pages are printed while using Adobe 8.
    We are trying to automate some tasks for which we require the PDF files to be printed automatically through a DOS command. We are being advised to use Adobe 9 as technical support for Adobe 8 is likely to be withdrawn soon.
    Please can you help.

    Sorry. This is a forum for Adobe Connect issues not PDF issues. Please locate the correct forum so your question can be addressed properly there.

Maybe you are looking for

  • Counter function value to multiple elements as same value in different node

    I need your help! I have a counter function and value of that needs to be passed to two elements of Node A and Sub Node B.. Ex: Mapping Map Counter function to NodeA.Element1 and also to NodeB(subnode).Element2 Expected Result: NodA.Element1 = 1 Node

  • Size of TIFF files for Full Bleed in InDesign?

    I am doing a layout for a 8x10 landscape children's picture book.  Every page is a simple full bleed of an image with reverse (white) text boxes. In my PS files, I have built in the 1/8" bleed and made them 8.25x10.25, however, when I place these int

  • T500 Displayport sound issue

    Hello there, Does anyone can explain, how to enable sound via displayport on Lenovo T500 with Ati Mobility Radeon HD 3650 and Conexant 20651 SmartAudio HD? I've got adapter for HDMI cable, with my T520 it works perfect (with sound) and with T500 it d

  • Artist appear more than once on my ipod

    When i search through my music using artist as the criteria, one artist lists several times. i.e. Alicia Keys, i noticed that this was because not all her song was in the same folder so i fixed this in itunes. and synchronized the ipod. there is stil

  • Start up error - can't decode JSPrincipals

    I'm receiving this error when opening DW CS3, Windows Vista: The following JavaScript error(s) occurred: InternalError: can't decode JSPrincipals. DW seems to continue to open and operate properly. Does anyone know what causes this & how to correct?