Use code to generate barcode
no vote
if (string.IsNullOrWhiteSpace(this.BarCodeText)) throw new ArgumentException("BarCode must be set prior to calling Generate"); // Ensure BarCode does not contain invalid characters } // Determine the barcode width var widthOfBarCodeString = 0; var wideToNarrowRatio = 2.0; for (var i = 0; i < encodedString.Length; i++) {