Print PDF file directly to store printer

Hi Gurus,
Having not found a solution, we think we need help from you. We have searched forums and google but have not found adequate solutions.
We are a retailer having different stores. Our main office is using SAP. Each store has its printer and defined in our SAP system. We want to print PDF files directly to store printer using SAP . How should we do that ? We think there are 2 steps:
1) Upload PDF files from network directory into SAP (We done it, no problem)
2) Having now PDF files in internal tables, how should we proceed to print PDF files using store printers?
     Please note that we do not want to use CL_GUI_PDFVIEWER since we do not want to display the PDF and having the obligation to choose the print option from dialog and also we do not want to call Adobe OLE object  to print
Any answer would be appreciated
Thank you very much

Hi,
It is really late to give response this post. But still who ever refering to this post for the same issue this solution is useful for achieving same in background:
Even same can be used in smartforms, for getting spool request in PDF format as well which will decrease the size of file when printing in SAP printer.
ct_tline is PDF output:
DATA: lv_pdfsource TYPE xstring.
FIELD-SYMBOLS:<p> TYPE x. " <p> type any.
LOOP AT ct_tline INTO cs_tline.
  ASSIGN cs_tline TO <p> CASTING TYPE x.
  CONCATENATE lv_pdfsource <p> INTO lv_pdfsource IN BYTE MODE.
ENDLOOP.
* ->Create spool request in PDF format
CALL FUNCTION 'ADS_CREATE_PDF_SPOOLJOB'
  EXPORTING
    printer  = 'LOCL'            "Printer name supporting PDF device type
*   DEST     =
    pages    = 1
    pdf_data = lv_pdfsource        "XSTRING internal table
*   NAME     =
*   SUFFIX1  =
*   SUFFIX2  =
*   COPIES   =
*   PRIO     =
    IMMEDIATE_PRINT         = 'X'
*   AUTO_DELETE             =
*   TITLELINE               =
*   RECEIVER =
*   DIVISION =
*   AUTHORITY               =
*   LIFETIME = '0'
* IMPORTING
*   SPOOLID  =
* EXCEPTIONS
*   NO_DATA  = 1
*   NOT_PDF  = 2
*   WRONG_DEVTYPE           = 3
*   OPERATION_FAILED        = 4
*   CANNOT_WRITE_FILE       = 5
*   DEVICE_MISSING          = 6
*   NO_SUCH_DEVICE          = 7
*   OTHERS   = 8
IF sy-subrc <> 0.
* Implement suitable error handling here
ENDIF.

Similar Messages

  • Orarrp can't print pdf file directly to printer

    oracle remote print utility (orarrp) can't print pdf file directly to printer.
    we expect orarrp utility can handle ".rrpa" file (i.e. pdf file generated on the application server) by directly print the file to the client's printer, i.e. invoke the acrobat reader on the client side, display the the printer selection dialogue, after confirmation print the pdf file, then the acrobat reader close automatically nicely.
    However we are disappointed as the acrobat reader startup and display the pdf file content but does not print and does not close.
    After testing the problem several times, there are some findings:-
    Finding (A):-
    (a) for the success of direct printing of pdf file, a physical path must be provided; we have tried 2 methods:
    1) using drag & drop to copy the pdf file directly to the browser
    2) open pdf file in the browser directly using browser menu-->File-->Open.
    (b) for the failure of direct printing, a virtual path is involved and we have also tried 2 methods:
    1) when web.show_document() is used
    2) enter the url to the URL bar of the browser,
    eg. http://appsvr.com:7777/report/test_printout/APPSVR1094707.rrpa (this is a virtual path/url)
    Finding (B):-
    (a)when the physical path is used, a temporary pdf file is generated in the same directory where the rrpa file exists in the application server,
    e.g. in application server: d:/printout/yyy.pdf is generated for d:/printout/xxx.rrpa when direct print occurs
    (b) however when the virtual path is used, there is no such temp "pdf" file generated and direct print failed.
    May be when virtual path is used, orarrp utility don't know where to generate the temp "pdf" so direct print doesn't occur.
    So, anyone has similar experience or further queries or has solutions, please join.
    Thanks for your attention.

    Hi,
    It is really late to give response this post. But still who ever refering to this post for the same issue this solution is useful for achieving same in background:
    Even same can be used in smartforms, for getting spool request in PDF format as well which will decrease the size of file when printing in SAP printer.
    ct_tline is PDF output:
    DATA: lv_pdfsource TYPE xstring.
    FIELD-SYMBOLS:<p> TYPE x. " <p> type any.
    LOOP AT ct_tline INTO cs_tline.
      ASSIGN cs_tline TO <p> CASTING TYPE x.
      CONCATENATE lv_pdfsource <p> INTO lv_pdfsource IN BYTE MODE.
    ENDLOOP.
    * ->Create spool request in PDF format
    CALL FUNCTION 'ADS_CREATE_PDF_SPOOLJOB'
      EXPORTING
        printer  = 'LOCL'            "Printer name supporting PDF device type
    *   DEST     =
        pages    = 1
        pdf_data = lv_pdfsource        "XSTRING internal table
    *   NAME     =
    *   SUFFIX1  =
    *   SUFFIX2  =
    *   COPIES   =
    *   PRIO     =
        IMMEDIATE_PRINT         = 'X'
    *   AUTO_DELETE             =
    *   TITLELINE               =
    *   RECEIVER =
    *   DIVISION =
    *   AUTHORITY               =
    *   LIFETIME = '0'
    * IMPORTING
    *   SPOOLID  =
    * EXCEPTIONS
    *   NO_DATA  = 1
    *   NOT_PDF  = 2
    *   WRONG_DEVTYPE           = 3
    *   OPERATION_FAILED        = 4
    *   CANNOT_WRITE_FILE       = 5
    *   DEVICE_MISSING          = 6
    *   NO_SUCH_DEVICE          = 7
    *   OTHERS   = 8
    IF sy-subrc <> 0.
    * Implement suitable error handling here
    ENDIF.

  • Can't print .pdf files on windows network printer

    Hi,
    I cannot print .pdf files on Canon IRC printer with UFR II 2.23 or 2.24 drivers connected through a windows network by LDP protocol, either with Apple Preview or Acrobat Reader - looks like the software doesn't find the printer (I have the rainbow whell and the software does not answer). It can last for hours, there is no other solution than forcing the soft to quit and finding another way to print. I have updated Canon drivers from 2.23 to 2.24 (all supposed to work with Lion) and that does not fix the problem.
    This problem does not happen with Ms Word or Safari (or, more generally, other types of files) and it worked fine with Snow Leo even with pdf!! I also have windows XP with Parallels and guess what? I can print through Parallels with Acrobat Reader (for windows XP) on the same printer on which I cannot print with my Mac with Lion and Preview or Acrobat Reader for Mac!
    Please help !!
    Alexis

    Correction
    It works with Acrobat but the printer does not like queues of documents...
    The site privided me with the topics I fas looking for about this : it's a Canon drivers and Lion permissions problem.

  • Print pdf file directly from a folder, Adobe Reader X in  Windows Server 2003

    In previous versions of Adobe Reader we were able to print pdf files groupwise directly when selected in a folder.
    Now I've installed Reader X on the Windows Server 2003 environment. Logged in as administrator I can still select <Print> by selecting the right mouse button in a folder. Logged in as a user, this is not available.
    I checked user-rights and permissions and made sure they have full control.
    Someone who can help us in this matter?
    Thanks

    Thanks for your reply.
    The file menu doesn't show the print option either. We used to work this way, after installing the 9.0 and Reader X version, this option has disappeared from both the File menu and the right mouse button. For other filetypes, for example Excel the Print option is still available and works properly. Logged in as administrator on the serverconsole, there is no problem. So it seams to be something specific to pdf-formats in a server 2003 environment. The userrights are all set on full control (same as administrator).
    Thanks again

  • How to  print pdf file by using java print API ? I am trying with this code

    import java.io.FileInputStream;
    import java.io.InputStream;
    import javax.print.Doc;
    import javax.print.DocFlavor;
    import javax.print.DocPrintJob;
    import javax.print.PrintException;
    import javax.print.PrintService;
    import javax.print.PrintServiceLookup;
    import javax.print.SimpleDoc;
    import javax.print.attribute.HashPrintRequestAttributeSet;
    import javax.print.attribute.PrintRequestAttributeSet;
    import javax.print.attribute.standard.Copies;
    import javax.print.attribute.standard.MediaSizeName;
    public class PDFPrint {
    static public void print(InputStream inputStream, PrintService printService) throws PrintException {
    Doc doc = new SimpleDoc(inputStream, DocFlavor.INPUT_STREAM.AUTOSENSE, null);
    PrintRequestAttributeSet attributes = new HashPrintRequestAttributeSet();
    attributes.add(MediaSizeName.ISO_A4);
    attributes.add(new Copies(1));
    print(doc, attributes, printService);
    }//print()
    static public void print(Doc doc, PrintRequestAttributeSet attributes, PrintService printService) throws PrintException {
    if (printService == null) {
    printService = PrintServiceLookup.lookupDefaultPrintService();
    System.out.println("The Printer Name is :"+printService.getName());
    DocPrintJob docPrintJob = printService.createPrintJob();
    System.out.println("Before Print Start()");
    docPrintJob.print(doc, attributes);
    }//print()
    public static void main(String args[])
    PrintService defaultPrintService = PrintServiceLookup.lookupDefaultPrintService();
    String file="c:/BackUp/file.pdf";
    FileInputStream fis=new FileInputStream(file);
    System.out.println("Before Print() called ..");
    print(fis,defaultPrintService);
    System.out.println("After Printing....");
    I am using this code to print pdf file. But when I try this one automatically the printer starting with print ascii codes with infinite loop.
    I am using jdk1.4,Acrobat 8.0, Windows environment.
    Can u help me in this regard'
    Thank u
    grani

    import java.io.FileInputStream;
    import java.io.InputStream;
    import javax.print.Doc;
    import javax.print.DocFlavor;
    import javax.print.DocPrintJob;
    import javax.print.PrintException;
    import javax.print.PrintService;
    import javax.print.PrintServiceLookup;
    import javax.print.SimpleDoc;
    import javax.print.attribute.HashPrintRequestAttributeSet;
    import javax.print.attribute.PrintRequestAttributeSet;
    import javax.print.attribute.standard.Copies;
    import javax.print.attribute.standard.MediaSizeName;
    public class PDFPrint {
    static public void print(InputStream inputStream, PrintService printService) throws PrintException {
    Doc doc = new SimpleDoc(inputStream, DocFlavor.INPUT_STREAM.AUTOSENSE, null);
    PrintRequestAttributeSet attributes = new HashPrintRequestAttributeSet();
    attributes.add(MediaSizeName.ISO_A4);
    attributes.add(new Copies(1));
    print(doc, attributes, printService);
    }//print()
    static public void print(Doc doc, PrintRequestAttributeSet attributes, PrintService printService) throws PrintException {
    if (printService == null) {
    printService = PrintServiceLookup.lookupDefaultPrintService();
    System.out.println("The Printer Name is :"+printService.getName());
    DocPrintJob docPrintJob = printService.createPrintJob();
    System.out.println("Before Print Start()");
    docPrintJob.print(doc, attributes);
    }//print()
    public static void main(String args[])
    PrintService defaultPrintService = PrintServiceLookup.lookupDefaultPrintService();
    String file="c:/BackUp/file.pdf";
    FileInputStream fis=new FileInputStream(file);
    System.out.println("Before Print() called ..");
    print(fis,defaultPrintService);
    System.out.println("After Printing....");
    I am using this code to print pdf file. But when I try this one automatically the printer starting with print ascii codes with infinite loop.
    I am using jdk1.4,Acrobat 8.0, Windows environment.
    Can u help me in this regard'
    Thank u
    grani

  • Unable to print PDF file in HP deskjet printer ink advantage 1515

    Hi , currently i have difficulty in using my printer(HP deskjet  printer ink advantage 1515 ) to print PDF file, but Microsof word and powerpoint is ok,, so , any idea?

    You are welcome!
    I have a few more suggestions for you to try that might help. You can try printing your PDF file by using another program, or you can try running the Print and Scan Doctor. This diagnostic tool will check for any conflicts that could be causing the issue. The tool will show you a report at the end. If there was a problem that the tool could not fix, you will notice it in the results.If there was no issues detected, you can also try Uninstalling the Printer Software from the Control Panel, restarting your PC and reinstall the full driver here: HP Deskjet Ink Advantage 1515 All-in-One Printer 
    If the PDF's not printing was due to an issue with the printer software, the issue would be resolved by uninstalling and reinstalling the printer. If the problem continues, try posting this issue in the Adobe Forums for further assistance.
    Have a great day
    R a i n b o w 7000I work on behalf of HP
    Click the “Kudos Thumbs Up" at the bottom of this post to say
    “Thanks” for helping!
    Click “Accept as Solution” if you feel my post solved your issue, it will help others find the solution!

  • How to print pdf's direct to default printer by command line

    I want to direct print pdf's to the default printer by command line.
    this work's with:
    C:\Programme\Adobe\Reader 11.0\Reader\AcroRd32.exe /n /s /h /t test.pdf
    But at the end, when printing was done. Adobe does not close automatically.
    Is there an opportunity to automatically close adobe after printing?

    No, Adobe stopped that happening many releases ago, for reasons that I don't understand but they will not change.

  • How to print PDF files directly from SAP?

    We have created output that is being saved in a PDF format. We can store it on any drive or send it through email. However, we would like to be able to print a PDF file directIy without any manual intervention. Now users still have to open the file and hit the print button and we want to avoid this. So basically we want to be able to create e.g. a sales order, generate an order confirmation in PDF format and send it directly to the output device that we stored in output master data. I have a feeling it is not possible to print directly because output device has to be like a PDF1 to create the PDF file itself and there is no space left somewhere to store the physical output device. We use ECC 5.
    kind regards
    Angelique Heutinck

    You can use this custom FM -:)
      FUNCTION Z_PDF_DOWNLOAD.
    *"*"Interfase local
    *"  IMPORTING
    *"     REFERENCE(FILENAME) TYPE  STRING
        SELECT RQIDENT
        INTO (T_TSP01-RQIDENT)
        FROM TSP01
        WHERE RQOWNER EQ SY-UNAME
          AND RQCLIENT EQ SY-MANDT.
        APPEND T_TSP01.
        ENDSELECT.
        SORT T_TSP01 DESCENDING.
        CALL FUNCTION 'CONVERT_OTFSPOOLJOB_2_PDF'
             EXPORTING
                  SRC_SPOOLID              = T_TSP01-RQIDENT
                  NO_DIALOG                = ''
             IMPORTING
                  PDF_BYTECOUNT            = NUMBYTES
                  PDF_SPOOLID              = PDFSPOOLID
                  BTC_JOBNAME              = JOBNAME
                  BTC_JOBCOUNT             = JOBCOUNT
             TABLES
                  PDF                      = PDF
             EXCEPTIONS
                  ERR_NO_OTF_SPOOLJOB      = 1
                  ERR_NO_SPOOLJOB          = 2
                  ERR_NO_PERMISSION        = 3
                  ERR_CONV_NOT_POSSIBLE    = 4
                  ERR_BAD_DSTDEVICE        = 5
                  USER_CANCELLED           = 6
                  ERR_SPOOLERROR           = 7
                  ERR_TEMSEERROR           = 8
                  ERR_BTCJOB_OPEN_FAILED   = 9
                  ERR_BTCJOB_SUBMIT_FAILED = 10
                  ERR_BTCJOB_CLOSE_FAILED  = 11
                  OTHERS                   = 12.
        IF SY-SUBRC EQ 0.
          CALL FUNCTION 'GUI_DOWNLOAD'
               EXPORTING
                    BIN_FILESIZE            = NUMBYTES
                    FILENAME                = FILENAME
                    FILETYPE                = 'BIN'
               TABLES
                    DATA_TAB                = PDF
               EXCEPTIONS
                    FILE_WRITE_ERROR        = 1
                    NO_BATCH                = 2
                    GUI_REFUSE_FILETRANSFER = 3
                    INVALID_TYPE            = 4
                    NO_AUTHORITY            = 5
                    UNKNOWN_ERROR           = 6.
          IF SY-SUBRC EQ 0.
            DELETE FROM TSP01 WHERE RQIDENT EQ T_TSP01-RQIDENT.
          ENDIF.
        ENDIF.
      ENDFUNCTION.
    Greetings,
    Blag.

  • Printing PDF report directly to printer, not using orarrp utility

    The orarrp utility works only with Windows machines and it
    requires installation on both the client machines and servers to
    support. We need a more general solution.
    Adobe has a java application/applet/javabean (and support
    classes) to view PDF, and it is easy to write a java driver
    which can be used in place of the orarrp utility. However,
    Adobe's Java Viewer is extremely slow, does not produce quality
    output, and is explicitly not supported by Adobe.
    My question then relates to Reports. When the Report server
    returns a PDF in the Previewer, I'm expecting the JINITIATOR,
    used by Forms, is also used to support the Report frame and
    functionality, including eventual printing. If this is the case,
    is there not a set of classes, downloaded with Jinitiator, which
    support the fonts, and printing of PDF to locally attached
    printers?
    And if so, shouldn't we, in Java, be able to make use of these
    classes and their APIs to print PDF files directly to locally
    attached printers without the need for Previewing first?

    within a forms trigger:
    1. generate the report
    2. copy from iAS to local
    like: webutil_file_transfer.url_to_client()
    3. print.exe /d:printer filename (for windows OS)

  • How to print pdf files not using acrobat product?

    i just want to print pdf files,but not want to use the adobe acrobat or acrobat reader,just want to write a tools print pdf files directly.

    > no i just want to print it,not need to read it.can you help me?
    Well, the problem is to print it you need to be able to read it. Something needs to convert it into a format the printer can understand (most printers are PostScript or PCL).
    I'm not sure you entirely understand what a PDF file is. It's not a fancy text file. It's a binary format. Saying "I want to print a PDF without a PDF interpreter" is like saying "I want to run an EXE without Windows". You need software to interpret the format.
    You certainly can write your own software to interpret the PDF format, convert it to a print language and output that to a printer, but as Aandi said you will need to start by reading the PDF Reference so you know how the inside of a PDF file works, and it will most likely take several years of development even for a seasoned, expert programmer. It's just not as simple as "Printer, meet PDF. PDF, meet printer."

  • Printing pdf files E90

    Its all fine that we can view pdf files on the Nokia E90. What if I wanted to print a pdf file to a printer like I can print emails and other documents. I cannot find a print menu for this on the Nokia E90.

    I guess you can't print pdf files direct from E90, but through your PC Nokia PC suite. I've tried to print from USB port from E90, but couldn't make a connection.

  • Adobe reader 11.0.5 - cannot print pdf file to network printer

    I have a 64 bit HP Pavilion a6230n PC running Windows 7, fully updated. I have wireless connection to a home file/printer server. My printer, a Brother HL-5140, is connected via USB to the file/printer server. All my other Windows programs capable of printing can print on the network printer - all except adobe reader. Adobe Reader sees the printer and all printing processes appear to be sending the file to the printer, however, the printer never gets the document. I've tried printing as a document, in which case the document sits in the printer queue until I delete it. If I send it as an image, each queue entry is deleted after adobe thinks it has printed. Again, nothing ever prints on the printer, and again, no other program running on my computer has any problems printing to this printer.
    I would appreciate any help with this problem.
    Addendum - 4 Nov 13:
    I uninstalled adobe reader 11 and installed a much earlier version, and now I can print pdf files. Clearly the printing issue is with the current versions of adobe reader.

    This phenomenon can happen with PDF files that have errors in them.  Adobe Reader or Acrobat may be able to fix these errors, but if you close the application, it will ask to save the corrected file.  If you save it once, that should no longer occur when you open it again.
    This is just one explanation, but it doesn't explain why that happens with every PDF you have.
    Test: does it also happen with a PDF that is not supposed to contain any errors: http://helpx.adobe.com/pdf/adobe_reader_reference.pdf ?

  • HP LaserJet Pro CM1415fnw Color Multifunction Won't Print PDF Files

    I recently encountered a problem where my HP LaserJet Pro CM1415fnw Color Multifunction would not print PDF files.  I tried printing from Preview, Adobe Reader, Word and PDF Pen Pro and the document would not print.  But the printer had no problem printing other formats such as JPG, DOCX etc. from the same computer both before and after.
    What happened is that the computer indicated it sent the document to the printer and the printer screen showed "Printing Document" momentarily - but then the the printer screen would return to the Ready screen and the document would not print.  There were not indications that the printer was having a problem.
    I reinstalled the HP drivers - no change.
    Finally I was able to print the document by opening in Photoshop and saving it as a JPG.
    I am running OSX 10.9.2.  on a MacBook Pro.
    This question was solved.
    View Solution.

    Hi 5teve,
    Welcome to the HP Forums, I hope you enjoy your experience!
    I understand you are unable to print PDF documents.
    I will be happy to help you.
    Check the driver name. If it shows HP Laserjet CM1415 - Airprint it would be the Apple driver.
    Delete it and add the new driver in for just the HP Laserjet CM1415. You might have to click on the drop down to select it from the list.
    Here is a screen shot for a example. Different printer showing though.
    Please let me know the results.
    Thank you for posting on the HP Forums.
    Have a great day!
    Please click “Accept as Solution ” if you feel my post solved your issue, it will help others find the solution.
    Click the “Kudos Thumbs Up" on the right to say “Thanks” for helping!
    Gemini02
    I work on behalf of HP

  • Unable to print PDF files to HP Colour Laser Printer

    Hi Guys,
    I am having a problem with printing PDF files to a network printer. The printer was purchased recently and is a HP Colour LaserJet CP3525n all in one, printer/photocopier etc. Other documents such as Word documents work, so I don't think its a straight forward issue...
    I can print PDF file to other printers, so I know the PDF files themselves are not at fault.
    When I try and print to that printer, I just get pages and pages of funny characters coming up on the page... It doesn't matter what sort of PDF file I print either...
    Are there any settings I can change that may help me resolve the issue. The printer is networked and shared amongst 4 people.
    Any help would be appreciated.
    Ambrish

    This problem has been reported to occur with certain Lexmark and Dell printers. These printers include the following:
    Lexmark Z700-P700
    Lexmark X1180
    Lexmark X1170
    Lexmark X1150
    Lexmark P706
    Lexmark Z25
    Dell A940 (Personal All-in-One)
    Microsoft has several possible solutions here
    http://support.microsoft.com/kb/918730

  • Hp 3030 mfp won't print pdf files in windows 7 it

    I am unable to print pdf files/documents and I am unable to scan documents into pdf format.

    Hi there @jdwigg ,
    Welcome to the HP Forums!
    I read your post, and I hope to help out! As you are able to print successfully from your Windows 7 laptop, the printer is functioning fine, and the issue is most likely software related to your Windows 8.1 computer.
    Here are some links I would recommend you check out to see if they can help with the problem printing PDF files:
    Re: can't print pdf from the new windows 8.1
    Windows 8.1 Reader app unable to print PDF - prints fine with acrobat
    Also try updating Adobe or getting the latest version: Adobe Flash Player Support Center 
    I hope this helps, have a great Monday
    R a i n b o w 7000I work on behalf of HP
    Click the “Kudos Thumbs Up" at the bottom of this post to say
    “Thanks” for helping!
    Click “Accept as Solution” if you feel my post solved your issue, it will help others find the solution!

Maybe you are looking for

  • HT1766 Managing multiple devices (iPhones) on one account

    I just purchased an iPhone 4S for my daughter.  I would like to sync it with my iTunes account, but it wants to sync with my already established backup for my iPhone 3GS. Can we use the same account / Apple ID to manage these two phones, or do I have

  • Limiting the no. of users for a particular application in Portal?

    Hi, I want to know how this can be done. Following is the requirement: 1)I have an iView in Portal which is showing some BSP appliation. Now i want to restrict the no of users to only 600 for that particular iView only i.e. even though our portal can

  • Adobe Flash Player 10.2.152.32 Not working in I.E.8

    Hello I am getting a bit frustrated with Adobe Flash Player. The last three versions i have tried have all exhibited the same strange behaviour in that every clip i play on youtube or in other sites including CNN go frame by frame , maybe 1 frame a s

  • IMac cannot cannect to internet through Router

    Hello, I have an iMac G5, latest OS Tiger, Windows XP PC, Linksys WRT54Gv5 wireless broadband router, and DSL modem. The PC connects to the Linksys router, along with the DSL Modem. The iMac is connected wireless to Linksys router. I have no problems

  • I am running windows 8. cannot get itunes to install on my computer

    I tried upgrading to newere version of itunes, and then it would not run, it said not responding. I have tried 3 times to unistall itunes 3 times and then reinstall and nothing happens. I am nearly at the end of my rope with this, I am getting upset