#11 EAN-128 patch

closed
nobody
None
5
2007-01-14
2006-08-08
Anonymous
No

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&#xF1;910112345678912345678&#xF0;"
render-mode="svg" id="fieldUpc">
<bc:ean128>
<bc:quiet-zone>1cm</bc:quiet-zone>
<bc:group-separator>&#xF1;</bc:group-separator>
<bc:check-digit-marker>&#xF0;</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

Discussion

  • birch

    birch - 2006-08-08

    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&#xF1;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)

     
  • Nobody/Anonymous

    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

     
  • Nobody/Anonymous

    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&#xF0;" 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>&#xF0;</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.

     
  • Jeremias Märki

    Jeremias Märki - 2007-01-14
    • labels: 729117 -->
    • status: open --> closed
     
  • Jeremias Märki

    Jeremias Märki - 2007-01-14

    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.

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks