63

Is there a decent free API/component for printing barcodes in C#?

2

3 Answers 3

59

Could the Barcode Rendering Framework at Codeplex GitHub be of help?

4
  • 4
    Hint - You need to download the source file in order to find some sample projects that show some examples. There doesn't appear to be anything on the website.
    – John M
    Oct 20, 2011 at 19:03
  • 9
    Quick an easy "Hello World" c# sample: Add Reference -> Browse -> Zen.Barcode.Core.dll. Then add in your code using Zen.Barcode Code39 Examples: Code39BarcodeDraw barcode39 = BarcodeDrawFactory.Code39WithoutChecksum; pictureBox1.Image = barcode39.Draw("Hello World", 40); PitureBox1 will now display the barcode type 39. It's readable by a scanner.
    – Patratacus
    Aug 16, 2013 at 16:54
  • How to use this for a web application.?
    – Ankur
    Aug 23, 2013 at 9:16
  • 4
    Does it work with .net core?
    – daneejela
    Feb 27, 2017 at 21:41
52

I do recommend BarcodeLibrary (already removed from codeproject), but https://github.com/barnhill/barcodelib looks like its copy on github.

Here is a small piece of code of how to use it.

        BarcodeLib.Barcode barcode = new BarcodeLib.Barcode()
        {
            IncludeLabel = true,
            Alignment = AlignmentPositions.CENTER,
            Width = 300,
            Height = 100,
            RotateFlipType = RotateFlipType.RotateNoneFlipNone,
            BackColor = Color.White,
            ForeColor = Color.Black,
        };

        Image img = barcode.Encode(TYPE.CODE128B, "123456789");
0
13

There is a "3 of 9" control on CodeProject: Barcode .NET Control

1
  • This is very basic. Creates only ONE type of barcode.
    – Elmue
    Mar 24, 2015 at 23:01

Not the answer you're looking for? Browse other questions tagged or ask your own question.