title: Barcode doesn't display in PDF using iText
body: <p>I'm using iText to dynamically generate PDF docs. Now I'm trying to dynamically create a barcode in this PDF. Adobe Live Cycle has a barcode function built-in. You can just drag the barcode text box on the page and it's created.</p>
  
  <p><strong>Problem:</strong><br>
  I placed the barcode field in the PDF. Then pass a number to the barcode field from the JSP page. But only the number appears. The barcode lines never display</p>
  
  <p>The number, 20099002, is visible on the PDF doc, but the barcode lines fail to appear. I tried several other barcode options in LiveCycle but the all give the same result. </p>
  
  <pre><code>    OurJavaPage.java 
      public class ExampleForm extends BaseOutput { 
      private static final Log LOG = LogFactory.getLog(ExampleForm.class); 
      public OutputStream generate() throws IOException, DocumentException { 
          ByteArrayOutputStream baos = new ByteArrayOutputStream(); 
          PdfReader reader; 
          reader = new PdfReader(BASEDIR + "MailingExample.pdf"); 
  
          PdfStamper stamper = new PdfStamper(reader, baos); 
          Participant participantHome = home.getParticipant(); 
          Set&lt;Location&gt; homeLocs = participantHome.getLocations(); 
  
          final AcroFields form = stamper.getAcroFields(); 
  
          setFormField(form, "addrNumber[0]", addrMaster.getStreetNum()); 
          setFormField(form, "dateMiddle[0]", formatDate("MM-dd-yyyy", new Date())); 
  
  // *********** Here's the problem *****************************
          setFormField(form, "Code128ABarcode1[0]", "20099002");
  // ************************************************************
  
          debugAcrobatForm("ExampleForm", form); 
          stamper.setFormFlattening(true); 
          stamper.close(); 
  
          return baos; 
      } 
  }
  </code></pre>
  
  <p><b>Operating System:</b> Linux<br>
  <b>Programming:</b> Java, .jsp, iText<br>
  <b>Software:</b> Adobe Live Cycle Designer ES 8.1<br></p>