Barcode generation library

Discussion in 'Additional Libraries' started by agraham, Mar 24, 2009.

  1. agraham

    agraham Expert Licensed User

    Here is a library I put together from various open source projects. I used it for generating bar codes to read off my computer screen when testing my

    It offers DataMatrix 2D barcodes and a variety of 1D barcodes. It could also generate QRcode 2D barcodes but that requires a large number of configuration files (5.8Mb!) and they won't zip up small enough for the forum to accept so I can't include them. That seems an excessive overhead to me when DataMatrix seems just as good and anyway QuickMark can decode the square format DataMatrix codes (but apparently not the rectangular ones!).

    As it is really only a "play with" library I don't intend to offer a help file as to produce valid barcodes you need to know some technical details about them, such as checksum calculations, so Google is probably best for that. The properties and methods of the objects should be straightforward to work out. The filetypes for SaveImage are "J" for jpg, "B" for bmp, "G" for gif and "P" for png.

    Attached Files:

    Last edited: Mar 24, 2009
  2. Bobbes

    Bobbes Active Member Licensed User

    Hi agraham,
    I want to save the image1.image on the Desktop but no file on saved.
    I used the BCenc.saveimage(image1.image,"B") but no pic saved.

    sorry for my bad english

  3. agraham

    agraham Expert Licensed User

    I'm afraid you are using it wrong. You give it the filepath as a string and it saves its' internal image to that file.

  4. Bobbes

    Bobbes Active Member Licensed User

    Thank you very much,
    now it runs perfectly.


  5. thecrowkaka

    thecrowkaka Member Licensed User

    Dear Agraham

    This is a fantastic library indeed.

    You should have built a Help file for this library. What does the Pixelarray stand for? how to use this?
    I want to have an array of "0" and "1" where a "0" corresponds to the white square and "1" corresponds to the black square in the datamatrix code.
    Can this pixelarray give me this array?
    If not then can you update this library to give such an array?

    Kaushik Kale.
  6. agraham

    agraham Expert Licensed User

    I gave the reasons why I didn't provide a help in the first post.

    Dim pixels(0,0) As Byte
    pixels = DMencoder.PixelArray

    gives the byte values of the bitmap of the barcode.
  7. thecrowkaka

    thecrowkaka Member Licensed User

    Thanks agraham
  8. thecrowkaka

    thecrowkaka Member Licensed User

    This library on Basic4Android

    Is this library available on Basic4Android if not can it be made available on B4A.
  9. agraham

    agraham Expert Licensed User

    No, it's not available on Basic4androd and it won't be as the amount of work needed to port it over is too large to be worth doing.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice