3 Replies Latest reply on Apr 25, 2014 5:56 AM by Catherine Kyle

    Barcode4j and Jboss 7.1

    hasnain raza Newbie

      I'm using Barcode4j and FOP to generate a PDF that contains a barcode. It works perfect on Jboss 5 GA version but on Jboss 7.1 i get following error :

      ERROR: 'The first argument to the non-static Java function 'org.krysalis.barcode4j.xalan.BarcodeExt.generate(result-tree, result-tree)' is not a valid object reference.' FATAL ERROR: 'Could not compile stylesheet'

      These are the sections of the stylesheet:

      xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
      xmlns:fo="http://www.w3.org/1999/XSL/Format"
      xmlns:barcode="org.krysalis.barcode4j.xalan.BarcodeExt"
      extension-element-prefixes="barcode"
      exclude-result-prefixes="fo">

      barcode generation:

      <fo:instream-foreign-object>
      <xsl:variable name="barcodeNumber">
       
      <xsl:value-of select="barcodeNumber" />
      </xsl:variable>
      <xsl:variable name="barcode-cfg">
       
      <barcode>
        
      <intl2of5>
        
      <height>18mm</height>
        
      <module-width>0.28mm</module-width>
        
      <human-readable><placement>none</placement>
        
      </human-readable>
        
      </intl2of5>
       
      </barcode>
      </xsl:variable>
      <xsl:copy-of select="barcode:generate($barcode-cfg, $barcodeNumber)"
      />

      I'm using jdk 1.6.27,Jboss 7.1

      Any help will be appreciated.