GdPicture.NET Reference Guide
Barcode1DReaderGetBarcodeValue Method (GdPictureImaging)
Example 





GdPicture14 Namespace > GdPictureImaging Class : Barcode1DReaderGetBarcodeValue Method
Barcode index. Must be between 1 and Barcode1DReaderGetBarcodeCount returned value.
Returns the value of a barcode detected by the Barcode1DReaderDoScan method.
Syntax
'Declaration
 
Public Function Barcode1DReaderGetBarcodeValue( _
   ByVal BarcodeNo As Integer _
) As String
public string Barcode1DReaderGetBarcodeValue( 
   int BarcodeNo
)
public function Barcode1DReaderGetBarcodeValue( 
    BarcodeNo: Integer
): String; 
public function Barcode1DReaderGetBarcodeValue( 
   BarcodeNo : int
) : String;
public: string* Barcode1DReaderGetBarcodeValue( 
   int BarcodeNo
) 
public:
String^ Barcode1DReaderGetBarcodeValue( 
   int BarcodeNo
) 

Parameters

BarcodeNo
Barcode index. Must be between 1 and Barcode1DReaderGetBarcodeCount returned value.

Return Value

The barcode data.
Remarks

This method is used in the "Barcode Recognition" Demo.

For UCC / EAN-128 codes FNC1 control character is mapped to the <GS> char (ASCII code 29).

Example
Detecting all barcodes in an image.
Dim oGdPictureImaging As New GdPicture.GdPictureImaging
Dim ImageID As Integer = oGdPictureImaging.CreateGdPictureImageFromFile("") 'Prompt the user to select an image
If imageId <> 0 Then
   If oGdPictureImaging.Barcode1DReaderDoScan(ImageID) = GdPictureStatus.OK Then 'Start barcode scanning process
      Dim BarcodeCount As Integer = oGdPictureImaging.Barcode1DReaderGetBarcodeCount()
      If BarcodeCount > 0 Then
         For i As Integer = 1 To BarcodeCount
            MessageBox.show("Barcode No: " & Str(i))
            MessageBox.show("Type: " & oGdPictureImaging.Barcode1DReaderGetBarcodeType(i).ToString)
            MessageBox.show("Value: " & oGdPictureImaging.Barcode1DReaderGetBarcodeValue(i))
            MessageBox.show("Angle: " & Str(oGdPictureImaging.Barcode1DReaderGetBarcodeSkewAngle(i)))
         Next
      Else
         MessageBox.show("No barcode detected !")
      End If
      oGdPictureImaging.Barcode1DReaderClear() 'Release detection info from memory
   End If
   oGdPictureImaging.ReleaseGdPictureImage(ImageID)
End If
See Also

Reference

GdPictureImaging Class
GdPictureImaging Members