title: Print custom invoice of page size (20.5 x 14 cm) using jasper report or iText for Java
body: <p>I want to print data on invoice receipt size of 20.5 x 14 cm(hard copy). In which I try to put text at some absolute location. I tried iText first. In that I try to set page size by following code.</p>
  
  <pre><code>    // here what is unite used in bracket of rectangle?
  
      Document document = new Document(new Rectangle(552,377));
  
  
      PdfWriter.getInstance(document, new FileOutputStream("report.pdf"));
      document.open();
      ...
      ...
      ...
      document.close();
  </code></pre>
  
  <p>Second I tried Jasper report. In that I set page size to 20.5 x 14 cm. But how can I take value from my java application's textfield and put it in to some absolute location in iReport.</p>
  
  <p>As I know jasper report take value from database but how can I take value from java application's textfiled?</p>
  
  <p>I am more familiar with iText. </p>
  
  <p>I will be thankful to any developer who can guide me how can I print custom invoice using iText or Jasper Report.I am developing java application using netbeans.</p>