我想用pdf中的代码39创建条形码,有人可以帮我写jrhtml文件来打印pdf
我在下面试过,但面临一些问题。是否有其他方法可以使用code39生成条形码。
<componentElement>
<reportElement x="353" y="42" width="200" height="50"/>
<jr:Code39 xmlns:jr="http://jasperreports.sourceforge.net/jasperreports/components" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports/components http://jasperreports.sourceforge.net/xsd/components.xsd" textPosition="bottom">
<jr:codeExpression>
<![CDATA[$P{printid}]]>
</jr:codeExpression>
</jr:Code39>
</componentElement>
答案 0 :(得分:1)
Python,使用reportlab和pyPdf能够将code39条形码放入文档中。这是一些示例代码的链接。
你需要Python,包括Reportlab和pyPdf(最后两个是Python库)
https://github.com/glokem/barcodepdf
此外,该回购邮件中包含的某些“代码段”代码可能对您有用......?
答案 1 :(得分:0)
获取代码39字体并使用该字体创建文档。 http://www.barcodesinc.com/free-barcode-font/