Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4170170

PrinterJob.getUserName() does not display anything.

XMLWordPrintable

    • 2d
    • 1.2fcs
    • 1.2fcs
    • sparc
    • solaris_2.6
    • Not verified



      Name: rrT76497 Date: 08/31/98


              import java.awt.*;
              import java.awt.print.*;

              public class SimpleTest {
                  public static void main(String args[]) {
                      PrinterJob printerJob = PrinterJob.getPrinterJob();
                      printerJob.setPrintable(new Printable()
                          { {System.out.println("Sucessfully Printable
      is created");}
                              public int print(Graphics graphics,PageFormat pf
      , int pageIndex) {
                                             return Printable.PAGE_EXISTS;
                          }});
                      System.out.println("The name of the
      user"+printerJob.getUserName()+";");
                   }
              }
          When printerJob.getUserName() is given in the println, no output
      comes to the console.
      ======================================================================

            mpeircesunw Michael Peirce (Inactive)
            rramsunw Ranganathan Ram (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: