Printing Techniques Advice

I need to add printing to my application, but am not sure how to go about it. My original plan was to use FOP to produce a PDF, display that in swing and then ask the user if they wanted to print it. However, after reading about it today, it seems like this might be a difficult method, with Adobe no longer supporting the java PDF bean. Then I thought about creating a panel with my data on it and getting java to print that, but I'm not sure if that is any better. Most (99%) of the time printing will be A4 portrait, but I wanted to allow for other page sizes and orientations. Can anyone recommend a technique I could use?
Thanks

this probably isnt how the more experienced would do it
but this is a start.
replace my variables with whatever.
this is printing a BufferedeImage that is 1024 by 658
public void Print(){
     PrinterJob printerJob = PrinterJob.getPrinterJob();
     Book book = new Book();
     book.append( this, pf );
     printerJob.setPageable(book);
     boolean doPrint = printerJob.printDialog();
     if (doPrint) {
     try {
     printerJob.print();
     } catch (PrinterException exception) {
     System.err.println("Printing error: " + exception);
public int print(Graphics g, PageFormat pf, int pageIndex) {
     Graphics2D g2d = (Graphics2D) g;
     g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
     g2d.translate( pf.getImageableX(), pf.getImageableY() );
     disableDoubleBuffering(mainpanel);
     // scale to fill the page
     double dl = pf.getImageableWidth();
     double dh = pf.getImageableHeight();
     double xScale = dl / (1024);
     double yScale = dh / (768);
     g2d.scale( xScale, yScale);
     // draw picture
     subpicture = picture.getSubimage(vzx, vzy, vzl, vzh);
     BufferedImage img = new BufferedImage( (int)dl, (int)dh, BufferedImage.TYPE_INT_ARGB);
     img = scaleImage(subpicture, 1024, 768);
     // black and white
     if( chBW.isSelected() == true ){
     img = convertBW(img);
     g2d.drawImage(     img,
                                             null,
                                             0,
                                             0 );
     enableDoubleBuffering(mainpanel);
     return Printable.PAGE_EXISTS;
public void disableDoubleBuffering(Component c) {
    RepaintManager currentManager = RepaintManager.currentManager(c);
    currentManager.setDoubleBufferingEnabled(false);
public void enableDoubleBuffering(Component c) {
    RepaintManager currentManager = RepaintManager.currentManager(c);
    currentManager.setDoubleBufferingEnabled(true);
}

Similar Messages

  • Unable to print remittance advice for certain quick payments

    Hi,
    This is regarding issue " Unable to print remittance advice for certain quick payments."
    Product version:11.5.10.2
    Description:
    -Customer has paid through the payment batch.But the payment batch data is not available in ap_inv_selection_criteria_all.
    -The status of the check is 'RECONCILLED'.
    -The payments have already been submitted to the bank and reconciled to bank statement lines.
    -While running "Send Separate Remittance Advices" concurrent program, some payments generated from Quick Payment are not available for selection for generation of remittance advice.
    Research:
    Search in the metalink but could not find any related issue.
    Could you please adivce me how to proceed on this issue.
    Thanks
    Subhalaxmi
    Edited by: user13536207 on Feb 13, 2012 12:43 AM
    Edited by: user13536207 on Feb 13, 2012 12:46 AM

    Found the problem.
    Paper size for those documents are actually A5 size.
    Solve it by adjusting the Scale to paper size in the printing option to the size that our printer is set to printout 
    which in my case is 'Letter'
    Hope this helps anyone who is encountering the same problem.

  • Printing payment advice in F110

    Hi all,
    I configured F110 in such a way that NO payment medium is created, so what it does now is that it selects my vendor line items and automatically clears them. For all cleared vendors I want to generate a payment advice. Again, without the need for a payment medium to be created.
    What I have already done:
    - In OBVU (payment methods in cpy code)  I set "Always pyt advice"
    - In OBVCU (payment method by country) I left the payment medium program (RFFO*) EMPTY
    - In OBVU (payming cpy codes) I entered my payment advice form
    When I run F110 it works fine including the clearing, but NO payment advices are generated. When I execute RFFOAVIS it say "no record selected".
    My questions:
    1) It is generally possible to use F110 WITHOUT generating a payment medium/using an RFFOxxxx program and print an advice ONLY?
    2) The description of RFFOAVIS is that it prints advices for accounts with a 0 BALANCE, is this the correct program at all for printing "nomal" payment advices?
    3) Anyone an idea why else no advices are generated?
    Thanks!
    Rene

    Hi,
    Yes, it is possible to send payment advices notes with payment media program with out payment media.
    In payment method for country you have to assign payment media program. Payment advice form should be assigned for your paying company code in FBZP.
    In report variant for your payment media program under print control Select u2018print payment advice notesu2019 only.
    Thanks!
    Raju

  • Print Payment Advices

    Hi,
    Is there any transaction which we can use to Print Payment Advice.
    Thanks,
    Srini

    HIi! check FBZ5 once.it may help you.

  • PRINTING PAYMENT ADVICES

    HI,
    I want to print payment advices for cash withdrawal from bank how i can do this?
    Can we print payment advices without cheque printing?
    please suggest alternative.
    Is there any other way to print manually created cheque's?
    Can any one know more about FREEFORM PAYMENT in Online payments?

    Hi,
    Is this requirement for withdrawl of petty cash from Bank Account. Probably, you will be posting an accounting entry for cash withdrawl as under:
       Dr. Cash A/c.
       Cr. Bank A/c.
    Under any circumstances, you have to post an accounting document in SAP system. Otherwise, it is not possible to balance the balance the books.
    If an accounting document is created, you can explore how to meet your Business requirement of printing payment advice. You can try using transaction codes F-53 and FBZ5.
    Thanks
    Murali.

  • ACH Printing Payment Advice

    FI Gurus,
    We are implementing ACH payment method, currently everythign seems to be fine, we are able to e-mail and fax payment advices thru BTE 000002040. I am trying to also be able to print payment advices but  can't figure it out. Can anyone tell me what exactly I have to do in order to be able to print payment advices for ACH?
    Also,
    How can you e-mail to multiple e-mails and fax to teh same vendor? I have entered various e-mails in teh master data, but I only get the first e-mail entered, and don't get fax either, I only get 1 option, either e-mail or fax.
    Your help will be greatly appreciated.

    Thanks for the feedback... We were able to figure out how to email to multiple email addresses.  Let me know if you need this information.  What we are facing now is an issue where the user exit we created has created an either or situation... 
    See below the text of the message logged with SAP, maybe you can offer a suggestion:
    During payment processing SAP processes each payment advice note once.
    Each time by default it is set to print the payment advice note to
    printer. Client had a requirement that they want to be able to email
    the payment advice note to vendors directly. We implemented a user
    exit and in that user exit we can only change how we deliver payment
    advice note (i.e. print or email or fax). In the user exit we
    developed we are changing this delivery method to email when there is a
    email address in vendor account. This user exit is called every time
    we print payment advice notes. We need a way to change the logic to
    allow email and print not just either or. To be able to print AND
    email we have to trick the system so that it processes the entire
    payment advice output again then we have to somehow surpass the user
    exit so that it does not change the delivery method and thus prints the
    payment advice note rather than emailing it. Thatu2019s where the
    complexity comes in. this is a payment run program so there are very
    few user exit available and the ones that are there are not useful for
    what we want to do.

  • This regarding cheque printing with advice

    hi experts
    This regarding cheque printing with advice
    i am using standard driver progarm : RFFOUS_C
                    standard layout             :F110_MX_CHEQUE(which is modified as per clients layout)
    In advice the line items (i.e) inv no ref no inv date like wise is segregated by invoice document no but as per  client i need to segrate these line items based on vendor invoice no  i.e
    ( reference document no) . how to do this i need help .
    there is any way that fuctional consultant can do this
    regards
    Siva Shanmugam.a.v.

    hi,
    use the form  F110_IN_AVIS for payment advice.
    configure this form in the FBZP.
    In the program RFFOUS_C we  have internal table TAB_Regup.
    this internal table will get the data from the REGUD, REGUH using function module.
    in the tab_regup u will get the required data like docuno,amount
    all.
    loop this and take the data wat ever u want
    Regards,
    Ramu

  • Make payment and print payment advice

    Hi Experts,
    We want to make payment to Vendors and Need to print Payment Advice and Cheque.
    Could you please suggest procedure with T-Code.
    Regards

    Use T CODE F110 Settings to be done in TCODE FBZP
    Regards
    Arun
    Edited by: Arun R on Dec 11, 2008 7:54 AM

  • Standard SMARTFORM  for Check Printing/ Payment Advice

    Hi All,
      I have one important question...
    Standard <b>Script</b> Check Print Program =  <b>RFFOUS_C</b>
    Standart Script Layout Name  = F110_PRENUM_CHCK
                                &  F110_D_AVIS
    We have to modify it as per client requirment.
        But I want to know the <b>Standard SMARTFORM & Standard Smartform driver Program for CHECH printing & payment advice ?????????????</b>
    Is there no Smartform for check printing or if exist then please guide me?????????????????

    hi umesh,
    1)anyone can help me,while extending idoc,i added one segment to idoc by extending debmas.that segment has two fields.while populating data to idoc,i am getting problem like VSV0001.exit is not allowing me to write the code.
    plz anyone can help me on this issue.if you did't understand this problem plz tell me how to extend the idoc.more concentration on while populating the data in to idoc.like which function module i have to use.in customer master idoc.debmas.i am new to this environment.plz help me.like complet work till completion of task.
    2)and my next assignment is in smartforms.plz let me know .i was created the screen.according to that screen.i have to make print program.plz tell me how to give the text elements.
    like we have given in scripts, page window and then F9 to give the text elements.and make the program.like that any one can tell me clearly.how to make the complete smartforms programs.
    plz this requirement is very very urgent,plz could you send it for my [email protected]
    advance thanks for your help.
    thansk&regards,
    radhiks.

  • Print pmt advice sheet one by one for giving document number ranges

    Hi experts,
    i developed payment advice program (used as scripts),just enter only one document number and it will print payment advice
    sheet for that document number only.Now my clnt requirement is they want to enter document numbers in the ranges (EX:10 to 20)
    so that payment advice sheets for all document ranges should be printed one by one.we can give input as SELECT-OPTIONS.
    After that where should i modify so that o/p is come as my clnt requirement.
    This report is developed using scripts.Anybody pls help me in this.

    In your program retrieve the data into tables (you probably now have as a structure)...or alternatively, write a small program that gets the data, then calls the SAPscript (probably through and ENTRY subroutine).
    If you put your data into tables in a program, just loop and do the entire form process for each document...remember to CLEAR all tables/structures used by the SAPScript itself...if not you'll "double up" each time you process a new document.

  • Printing payement advice note in language other than english

    Dear Expert Users
    We are trying to print payment advice notes in different local
    languages.
    We have maintained the vendor language as the local language(ex:
    Japanese)and tried printing the payment advice note and its appearing
    in English.
    Please note that we have maintained the transalation of the forms in
    local language.
    Any assistance in this regard will be highly appreciated .
    Pravin

    1) Can you check at the condition record level which language is your prinout getting fired.?
    2) You can also try logging in japanese language and check if you can see your standard texts correctly.
    3) Also check if your printer supports language other than English..

  • Printing Payment Advice and Payment Media for Manual Payments

    Hello Gurus,
    In my company, we process very few invoices in a day and we have opted for manual payment of invoices. When this payment is done, I will like to print both the payment media and payment advice for the manual payments that have been done for vendor invoices. Does anybody have an idea how I can go about this? Thanks in advance for your help.
    Cheers

    To print payment advices and payment media you can use transaction F-58. When you enter your bank details and printer details make sure you enter printer name for both the payment media and payment advices. Then it will print both.
    Hope this helps.
    Shail

  • Printing payment advice note in local language other than english

    Dear Expert Users
    We are trying to print payment advice notes in different local
    languages.
    We have maintained the vendor language as the local language(ex:
    Japanese)and tried printing the payment advice note and its appearing
    in English.
    Please note that we have maintained the transalation of the forms in
    local language.
    Any assistance in this regard will be highly appreciated .
    Pravin

    Hi,what exactly do you want to see in local language?Vendor's master data or Print form?

  • Line items not printed in check printing payment advice

    Hi, this is the first time i am implementing check printing module so need some help.
    I have used standard print program RFFOUS_C and sapscript form F110_PRENUM_CHEK
    when I create an invoice from FB60 and make payments through F-58, on printing it prints the check properly but no line items are displayed.
    Please tell me a step by step procedure on how to print the payment advice,i.e, the line items. Is it already in the standard program or do i need to code it. I am interested in the learning also, if anyone can give me details it would be helpful fr me to implement it easily understanding what I am actually doing...
    Any help soon is appreciated .

    Already everything(line items) exists in the program, if you want to add additional fileds to be displayed that are not existing in your program then you need to sub-routines instead of modifying the standard print program.
    Now, you say that your line items are not displayed in your output. For check printing there is some configurations and settings to be done by your functional consultant.. I guess some configuration is missing in your case, that lack the display of line items...check with your functional team on this....(they have to set the lines)
    Note: For more info on config check FBZP where form config will be done basing on company code.
    Regards,
    Sairam

  • Problem printing Payment Advice

    Hi,
    I am using tcode F110
    But when I do automatic payment transactions as following
    Job started                        
    Step 001 started (program SAPF110S,
    Log for proposal run for payment on
    End of log                         
    Step 002 started (program SAPFPAYM_S
    Step 003 started (program ZFIP001, v
    Program ZFIP001: No records selected
    Job finished                       
    But when i send it to Spool and take a print out
    Cheque print out comes twice always and Payment Advice comes once.
    Pls help
    Points will rewarded for right answer

    Hi
    It looks like you will have to look in F110S where you schedule all the related dependent parameters like print and list output.
    Check the Variant in F110S and you are likley to find an ansewer.
    Provide points if found usefull.
    Thanks,
    Praveen
    Message was edited by:
            Garapati Praveen

Maybe you are looking for

  • Error while deploying RPD

    Hi, Trying to deploy RPD thru EM, following standard procedure which I have been doing for long enough but now hit this issue, there is not much that I can understand in this any help would be appreciated: Message     Supplementary information regard

  • Multiple Reciver and Reciver Determination Condition is not working

    Hi, My Message is look like this . <?xml version="1.0" encoding="UTF-8"?> <dataroot generated="">     <ChartOfAccounts>         <glAcctNo>300000</glAcctNo>         <COA>CAUS</COA>         <acct_grp>SAKO</acct_grp>         <shortText>short text</short

  • Rebate VK344 - VK445

    Hi experts, During the transaction VBO3, i try to create a manual rebate payment. I have the following message : "Manual payment is not allowed fot this agreement type" (VK344). So, I try to define a manual payment in VB(2 but I have the message u201

  • Difficulty remapping keyboard shortcuts on OSX

    Pretty obscure problem here. I am trying to use the little-known OSX built-in method of remapping keyboard shortcuts (System Preferences>Keyboard>Keyboard Shortcuts>Application Shortcuts) to customize things, specifically to add a shortcut to access

  • Accessibility on a text object

    Can someone tell me how accessibility works for the text object please? Does the screen reader ignore the object? Or does it read the text contained in the field? Or do you have to copy the text into the "custom text" field under the accessibility ta