I am trying to implement a EAN-128 barcode with FOP to
be used with Openbravo. I have rebuild the library with
the patch. But something doesn't work.
The code I used for a code128 is:
<fo:table-cell>
<fo:block>
<fo:instream-foreign-object>
<bc:barcode
xmlns:bc="http://barcode4j.krysalis.org/ns"
message="(00)38437005258" render-mode="svg">
<bc:code128>
<bc:height>32mm</bc:height>
</bc:code128>
</bc:barcode>
</fo:instream-foreign-object>
</fo:block>
</fo:table-cell>
And works perfectly.
But now, I've been ask for a EAN-128 barcode.
The code I'm trying for a EAN-128 is:
<fo:table-cell><fo:block><fo:instream-foreign-object>
<bc:barcode xmlns:bc="http://barcode4j.krysalis.org/ns"
message="42012345ñ910112345678912345678ð"
render-mode="svg" id="fieldUpc">
<bc:ean128>
<bc:quiet-zone>1cm</bc:quiet-zone>
<bc:group-separator>ñ</bc:group-separator>
<bc:check-digit-marker>ð</bc:check-digit-marker>
<bc:human-readable>
<bc:omit-brackets>true</bc:omit-brackets>
</bc:human-readable>
</bc:ean128>
</bc:barcode>
</fo:instream-foreign-object></fo:block></fo:table-cell>
And it does NOT work.
Can someone help me? Is something wrong on the code? Or
it something related to the library rebuild on with the
patch? Can someone send me a properly working patched
library?
Thanks a lot in advance.
Galder
galderromo@gmail.com
Logged In: YES
user_id=947301
Hi
First of all: I hope you compiled the patch with the right
barcode4j version.
I never trieed it with the newest CVS Version.
If you have trouble I can send you my working jar-file.
Supposed your jar is ok:
Try it again without the last char (#xF0;) in the message:
message="42012345ñ910112345678912345678"
This should work.
You copied this message from the example, but you did not
copy the <template>
The template implements an (91)-USPS Confirmation Service
Barcode with automatic Check-Digit computation.
The standard (91)-Iplementation does not know an
Check-Digit, so the char #xF0; leads to an error.
If you want to print eg. an SSCC just use:
message="00123456789012345678"
or
message="001234567890123456785"
or
message="00123456789012345678&xF0;"
They all give you the Barcode:
(00)123456789012345675
BTW your original example (00)38437005258 does not realy
make sense to me:
(00) says you want an SSCC but 38437005258 is not a valid SSCC
(no 18 digits, wrong check-digit).
Hope this helps
Dietmar
(the author of the ean128 patch)
Logged In: NO
Hi Dietmar
Thanks for your answer.
I will really appreciate if you send me a working jar-
file. Just to make sure, after I change the message, is
not a problem with the jar but with the code.
I will also check the other things you suggest.
Thanks again,
Galder
Logged In: NO
Hi Dietmar:
I finally obtained the EAN128 code with your email
colaboration and firiazabal patch correction for FOP.
Actually I have a question. I use this code:
<fo:block>
<fo:instream-foreign-object>
<bc:barcode
xmlns:bc="http://barcode4j.krysalis.org/ns"
message="0038508000024000054ð" render-mode="svg"
id="fieldUpc">
<bc:ean128>
<bc:quiet-zone>1cm</bc:quiet-zone>
<bc:template>(00)n11+n6+cd</bc:template>
<bc:check-digit-marker>ð</bc:check-digit-marker>
<height>32mm</height>
<module-width>0.6mm</module-width>
<bc:human-readable>
<bc:omit-brackets>false</bc:omit-brackets>
</bc:human-readable>
</bc:ean128>
</bc:barcode>
</fo:instream-foreign-object>
</fo:block>
The problem is, the library doesn't draw the doublezero (00)
on the barcode. And I need it.
The question is: Does the library ommit the (00), (1), (20)
when the AI starts with 00, 1, 20, etc?
Thanks!
Galder.
Logged In: YES
user_id=225352
Originator: NO
Dietmar applied the patch. I've reviewed the code and wrote some basic documentation. Dietmar, I'd appreciate if you could look over the docs and improve where you think it's necessary.