Barcode Reader

4 posts, 0 answers
  1. Joel Palmer
    Joel Palmer avatar
    164 posts
    Member since:
    May 2009

    Posted 20 Oct 2014 Link to this post

    I've been playing with your Barcode Reader and assume I am doing something wrong or missing something. 

    First, is there a way to "push the Open button" from the library?  When I produce a barcode image, I'd like to just have it read that when I ask in code... not from the button.

    Secondly and more important, I can't get a good read.  I have created a demo app that I'd be happy to share.  I print a 128 barcode to PNG file.  Then, I attempt to read the value back using the reader and it never returns the value I entered into the barcode.

    Output Barcode to PNG File:
    SaveFileDialog dialog = new SaveFileDialog()
        DefaultExt = "png",
        Filter = "png (*.png)|*.png"
    if (dialog.ShowDialog() == true)
        using (Stream stream = dialog.OpenFile())
                new PngBitmapEncoder());

    Let me know if you want me to upload my demo app.
  2. Tsvetie
    Tsvetie avatar
    1517 posts

    Posted 23 Oct 2014 Link to this post

    Hello Joel,

    You can use the BarcodeDecoder class to decode images without the necessity of user interacting with the UI of the RadBarcode control to select an image. For example:

    BarcodeDecoder decoder = new BarcodeDecoder();
    decoder.ImageSource = new BitmapImage(uri);
    decoder.DecodingComplete += Decoded;

    I tested your code that exports the barcode control and the problem that I encountered when reading the exported image, was a result of the transparency. In order to resolve this problem you can set the Background of the control before exporting it. For example:
    <telerik:RadBarcode128 Grid.Column="1" x:Name="barCode" Height="90" Width="370" Text="CODE 128"
        Background="White" />

    On a side note, I would like to note that our barcode reader does not deal well with distorted, tilted or blurry images. In case this is a requirements for your application, I would recommend that you test the control thoroughly in order to decide whether it meets your requirements.


    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

  3. DevCraft banner
  4. ashhad
    ashhad avatar
    1 posts
    Member since:
    Nov 2015

    Posted 12 Nov 2015 in reply to Joel Palmer Link to this post

    Hi Joel I want your demo project. Please Upload your demo project.


  5. Joel Palmer
    Joel Palmer avatar
    164 posts
    Member since:
    May 2009

    Posted 12 Nov 2015 in reply to ashhad Link to this post

    It has been an entire year.  I'll forward it on to you when I come across it.
Back to Top