Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 3.5 > ASP.NET 3.5 Basics
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
ASP.NET 3.5 Basics If you are new to ASP or ASP.NET programming with version 3.5, this is the forum to begin asking questions. Please also see the Visual Web Developer 2008 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 3.5 Basics section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developersí questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
 
 
Thread Tools Display Modes
  #1 (permalink)  
Old September 19th, 2012, 05:30 AM
Registered User
Points: 23, Level: 1
Points: 23, Level: 1 Points: 23, Level: 1 Points: 23, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Sep 2012
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Default ASP.NET barcode image

I am trying my best to make an barcode image on the web site. It is like coupon and users could scan for the discount information and also it contains our web URL. I choose QR Code and write some vb codes below:

qrcode.Symbology = Aspper.Barcode.Symbology.QRCode
qrcode.CodeToEncode = "WWW.Aspper.com.30% off"
qrcode.X = 4
qrcode.Y = 4
qrcode.ImageFormat = System.Drawing.Imaging.ImageFormat.Png
qrcode.generateBarcodeToImageFile("C://QRCode.gif")

I did not see the barcode yet, please help me. I install the component on VS 2008 and drag and drop it to my web form.
  #2 (permalink)  
Old December 28th, 2012, 03:31 AM
Registered User
Points: 3, Level: 1
Points: 3, Level: 1 Points: 3, Level: 1 Points: 3, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Dec 2012
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default possible answer

Quote:
Originally Posted by aspbarcode View Post
I am trying my best to make an barcode image on the web site. It is like coupon and users could scan for the discount information and also it contains our web URL. I choose QR Code and write some vb codes below:

qrcode.Symbology = Aspper.Barcode.Symbology.QRCode
qrcode.CodeToEncode = "WWW.Aspper.com.30% off"
qrcode.X = 4
qrcode.Y = 4
qrcode.ImageFormat = System.Drawing.Imaging.ImageFormat.Png
qrcode.generateBarcodeToImageFile("C://QRCode.gif")

I did not see the barcode yet, please help me. I install the component on VS 2008 and drag and drop it to my web form.

This is what I wrote and it works.

Dim qrbarcode As BarcodeLib.Barcode.QRCode
qrbarcode = New BarcodeLib.Barcode.QRCode()

qrbarcode.Data = "111110000"

qrbarcode.ModuleSize = 3
qrbarcode.LeftMargin = 12
qrbarcode.RightMargin = 12
qrbarcode.TopMargin = 12
qrbarcode.BottomMargin = 12
qrbarcode.ImageFormat = System.Drawing.Imaging.ImageFormat.Png

' save barcode image into your system
qrbarcode.drawBarcode("c:/vbnet-qrcode.png")
If you still can not produce a barcode image, maybe you can see the FAQs page here.
  #3 (permalink)  
Old May 28th, 2013, 11:12 PM
Registered User
Points: 3, Level: 1
Points: 3, Level: 1 Points: 3, Level: 1 Points: 3, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: May 2013
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by neo mars View Post
This is what I wrote and it works.

Dim qrbarcode As BarcodeLib.Barcode.QRCode
qrbarcode = New BarcodeLib.Barcode.QRCode()

qrbarcode.Data = "111110000"

qrbarcode.ModuleSize = 3
qrbarcode.LeftMargin = 12
qrbarcode.RightMargin = 12
qrbarcode.TopMargin = 12
qrbarcode.BottomMargin = 12
qrbarcode.ImageFormat = System.Drawing.Imaging.ImageFormat.Png

' save barcode image into your system
qrbarcode.drawBarcode("c:/vbnet-qrcode.png")
If you still can not produce a barcode image, maybe you can see the FAQs page ASP.NET barcode generation guide.
This is good. The vb code I have used is this:
Imports OnBarcode.Barcode


Dim barcode As QRCode = New QRCode

'QRCode Barcode Basic Settings

'QRCode Valid data char set:
'numeric data (digits 0 - 9);
'alphanumeric data (digits 0 - 9; upper case letters A -Z;
'nine other characters: space, $ % * + - . / : );
'byte data (default: ISO/IEC 8859-1);
'Kanji(characters)
barcode.Data = "112233445566"

barcode.DataMode = QRCodeDataMode.Auto
barcode.Version = QRCodeVersion.V1
barcode.ECL = QRCodeECL.L

'Set the ProcessTilde property to true,if you want use the tilde character "~"
'to specify special characters in the input data. Default is false.

'1) 1-byte character: ~0dd/~1dd/~2dd (character value from 000 ~ 255);
' ASCII character '~' is presented by ~126;
' Strings from "~256" to "~299" are unused
' modified to FS, GS, RS and US respectively.
'2) 2-byte character (Unicode): ~6ddddd (character value from 00000 ~ 65535)
' Strings from "~665536" to "~699999" are unused
'3) for GS1 AI Code:
' ~ai2: AI with 2 digits
' ~ai3: AI with 3 digits
' ~ai4: AI with 4 digits
' ~ai5: AI with 5 digits
' ~ai6: AI with 6 digits
' ~ai7: AI with 7 digits
'4) ECI: ~7dddddd (valid value of dddddd from 000000 to 999999)
'5) SJIS: from ~9ddddd (Shift JIS 0x8140 ~ 0x9FFC and 0xE040 ~ 0xEBBF)
barcode.ProcessTilde = True

' Barcode Size Related Settings
barcode.UOM = UnitOfMeasure.PIXEL
barcode.X = 3
barcode.LeftMargin = 0
barcode.RightMargin = 0
barcode.TopMargin = 0
barcode.BottomMargin = 0
barcode.Resolution = 96
barcode.Rotate = Rotate.Rotate0

' Image format setting
barcode.ImageFormat = System.Drawing.Imaging.ImageFormat.Gif()
barcode.drawBarcode("c://qr-code.gif")
If you want to change the parameters of the barcode, you can read this barcode image settings in VB.NET.
  #4 (permalink)  
Old October 16th, 2013, 11:34 PM
Registered User
Points: 6, Level: 1
Points: 6, Level: 1 Points: 6, Level: 1 Points: 6, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2013
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by sewewe View Post
This is good. The vb code I have used is this:
Imports OnBarcode.Barcode


Dim barcode As QRCode = New QRCode

'QRCode Barcode Basic Settings

'QRCode Valid data char set:
'numeric data (digits 0 - 9);
'alphanumeric data (digits 0 - 9; upper case letters A -Z;
'nine other characters: space, $ % * + - . / : );
'byte data (default: ISO/IEC 8859-1);
'Kanji(characters)
barcode.Data = "112233445566"

barcode.DataMode = QRCodeDataMode.Auto
barcode.Version = QRCodeVersion.V1
barcode.ECL = QRCodeECL.L

'Set the ProcessTilde property to true,if you want use the tilde character "~"
'to specify special characters in the input data. Default is false.

'1) 1-byte character: ~0dd/~1dd/~2dd (character value from 000 ~ 255);
' ASCII character '~' is presented by ~126;
' Strings from "~256" to "~299" are unused
' modified to FS, GS, RS and US respectively.
'2) 2-byte character (Unicode): ~6ddddd (character value from 00000 ~ 65535)
' Strings from "~665536" to "~699999" are unused
'3) for GS1 AI Code:
' ~ai2: AI with 2 digits
' ~ai3: AI with 3 digits
' ~ai4: AI with 4 digits
' ~ai5: AI with 5 digits
' ~ai6: AI with 6 digits
' ~ai7: AI with 7 digits
'4) ECI: ~7dddddd (valid value of dddddd from 000000 to 999999)
'5) SJIS: from ~9ddddd (Shift JIS 0x8140 ~ 0x9FFC and 0xE040 ~ 0xEBBF)
barcode.ProcessTilde = True

' Barcode Size Related Settings
barcode.UOM = UnitOfMeasure.PIXEL
barcode.X = 3
barcode.LeftMargin = 0
barcode.RightMargin = 0
barcode.TopMargin = 0
barcode.BottomMargin = 0
barcode.Resolution = 96
barcode.Rotate = Rotate.Rotate0

' Image format setting
barcode.ImageFormat = System.Drawing.Imaging.ImageFormat.Gif()
barcode.drawBarcode("c://qr-code.gif")
If you want to change the parameters of the barcode, you can read this barcode image settings in VB.NET.
erh...here is the sample code of qr code in vb.net i know
'QR Code Version options, V1-V40 supported.
qrcode.QRCodeVersion = KeepAutomation.Barcode.QRCodeVersion.V10
'QR Code Version Error Correction Level, 4 modes (H, L, M, Q) supported.
qrcode.QRCodeECL = KeepAutomation.Barcode.QRCodeECL.H
'QR Code data mode, supporting AlphaNumeric, Auto, Byte, Customer, Kanji, Numeric
qrcode.QRCodeDataMode = KeepAutomation.Barcode.QRCodeDataMode.Auto
'Set QR Code valid input: All ASCII characters, including 0-9, A-Z, a-z, special characters. Length: variable.
qrcode.CodeToEncode = "vbQRCode"

'QR Code unit of measure: pixel, cm and inch
qrcode.BarcodeUnit = KeepAutomation.Barcode.BarcodeUnit.Pixel
'QR Code image resolution in dpi
qrcode.DPI = 72

'QR Code Size-related Settings
'QR Code bar module width (X dimention)
qrcode.X = 2
'QR Code bar module height (Y dimention), Y=X
qrcode.Y = 2
'Image margin size, minimum value is 4X on all four sides according to specification.
qrcode.LeftMargin = 8
qrcode.RightMargin = 8
qrcode.TopMargin = 8
qrcode.BottomMargin = 8
'Generate Data Matrix in Png, Jpeg, Gif, Bmp, Tiff image formats.
qrcode.ImageFormat = Drawing.Imaging.ImageFormat.Png
qrcode.generateBarcodeToImageFile("C://qrcode_4_vb.png")
  #5 (permalink)  
Old June 18th, 2014, 11:28 PM
Registered User
Points: 3, Level: 1
Points: 3, Level: 1 Points: 3, Level: 1 Points: 3, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2014
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

have you ever seen this article how to use barcode in asp.net
  #6 (permalink)  
Old October 9th, 2014, 11:00 PM
Registered User
Points: 3, Level: 1
Points: 3, Level: 1 Points: 3, Level: 1 Points: 3, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2014
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by aspbarcode View Post
I am trying my best to make an barcode image on the web site. It is like coupon and users could scan for the discount information and also it contains our web URL. I choose QR Code and write some vb codes below:

qrcode.Symbology = Aspper.Barcode.Symbology.QRCode
qrcode.CodeToEncode = "WWW.Aspper.com.30% off"
qrcode.X = 4
qrcode.Y = 4
qrcode.ImageFormat = System.Drawing.Imaging.ImageFormat.Png
qrcode.generateBarcodeToImageFile("C://QRCode.gif")

I did not see the barcode yet, please help me. I install the component on VS 2008 and drag and drop it to my web form.
I use ASP.NET QR Code Generator:
Add ASP.NET Barcode Generator Control to your Visual Studio ToolBox.
Copy "qrcode.aspx" and "qrcode.aspx.cs" to the folder where your aspx pages are generating barcodes.
Drag and drop "QRCodeWebForm" to your ASPX web forms.
Run the website to view the barcodes generated. To customize QR Code settings, view QR Code barcode settings.
  #7 (permalink)  
Old April 20th, 2015, 01:10 AM
Registered User
Points: 7, Level: 1
Points: 7, Level: 1 Points: 7, Level: 1 Points: 7, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Apr 2015
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

error when i use your code, please fix this
 


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
how add barcode scanner in asp.net project saurabh ASP.NET 3.5 Professionals 2 November 29th, 2012 10:35 PM
uplaod image in asp.net thillaiarasu ASP.NET 1.x and 2.0 Application Design 2 June 22nd, 2007 11:36 AM
Barcode Image Control Zaff Access VBA 2 October 31st, 2006 07:00 PM
image directory asp.net sand133 ASP.NET 2.0 Basics 1 August 21st, 2006 02:10 PM
embedded image in asp.net mu_ping ADO.NET 1 January 22nd, 2004 10:06 AM



All times are GMT -4. The time now is 03:09 PM.


Powered by vBulletin®
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.