Leadtools.Barcode Namespace > BarcodeReader Class : GetBarcodeReadOptionsType Method |
public static Type GetBarcodeReadOptionsType( BarcodeSymbology symbology )
'Declaration Public Shared Function GetBarcodeReadOptionsType( _ ByVal symbology As BarcodeSymbology _ ) As Type
'Usage Dim symbology As BarcodeSymbology Dim value As Type value = BarcodeReader.GetBarcodeReadOptionsType(symbology)
public static Windows.UI.Xaml.Interop.TypeName GetBarcodeReadOptionsType( BarcodeSymbology symbology )
ObjectiveC Syntax
function Leadtools.Barcode.BarcodeReader.GetBarcodeReadOptionsType( symbology )
public: static Type^ GetBarcodeReadOptionsType( BarcodeSymbology symbology )
In LEADTOOLS barcode read support, each BarcodeSymbology (or a group of BarcodeSymbology) is associated with a read options class that is a type derived from BarcodeReadOptions (the remarks section of this class contains a table that lists all the symbologies and option classes). You can get the System.Type of the class associated with a certain symbology by using this GetBarcodeReadOptionsType.
Note that some options classes are shared by more than one symbology, for example, BarcodeSymbology.UPCA and BarcodeSymbology.UPCE both use OneDBarcodeReadOptions. Hence, passing either of these symbologies to this method will return the same type.
BarcodeSymbology.Unknown is a special type that is used to instruct the engine to read all barcodes. It does not have an associated read options class and should not be used in this method, otherwise, an exception will be thrown.
This example will show how to use GetBarcodeReadOptionsType.
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2