QRCodeGenerator qrGenerator = new QRCodeGenerator();
QRCodeGenerator.QRCode qrCode = qrGenerator.CreateQrCode(textBoxQRCode.Text, QRCodeGenerator.ECCLevel.Q);
pictureBoxQRCode.BackgroundImage = qrCode.GetGraphic(20);
privatevoid Form1_Load(object sender, EventArgs e){OleDbConnection aConnection = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:/Demo/BarcodeDemoData.mdb");aConnection.Open();OleDbDataAdapter dataAdapter = new OleDbDataAdapter("select * from Customer", aConnection);DataSet ds = new DataSet();dataAdapter.Fill(ds);//add a new column named "Barcode" to the DataSet, the new column data type is byte[]ds.Tables[0].Columns.Add(new DataColumn("Barcode", typeof(byte[])));Matrix Barcode = new Matrix();Barcode. MatrixBarcode = MatrixBarcode. QRCode;foreach (DataRow dr in ds.Tables[0].Rows){Barcode.BarcodeData = (int)dr["CustomerId"] + "";byte[] imageData = Barcode.drawBarcodeAsBytes();dr["Barcode"] = imageData;}CrystalReport1 rpt = new CrystalReport1();rpt.SetDataSource(ds);this.crystalReportViewer1.ReportSource = rpt;aConnection.Close();
Code Example |
---|
Csharp :: How can I return image from controller asp.net |
Csharp :: create list in c# |
Csharp :: remove all array elements c# |
:: |
:: |
:: |
Csharp :: convert xml string to file c# |
:: |
:: |
Csharp :: how to select time and date in datetimepicker in c# |
:: |
:: if statement c# |
Csharp :: MissingPluginException (MissingPluginException(No implementation found for method Firebase#initializeCore on channel plugins.flutter.io/firebase_core) |
Csharp :: c# add button to messagebox |
Csharp :: c# list foreach |
:: The foreach Loop c# |
Csharp :: |
Csharp :: limiting the amount of decimal places c# |
:: check if an object is active unity |
Csharp :: |
Csharp :: |
Csharp :: |
Csharp :: |
Csharp :: |
Csharp :: c# max two values |
:: |
:: |
Csharp :: array declaration in c# |
:: append an array in c# |
Csharp :: Oculus Unity button press |