DBR_DecodeFile Function

Decodes barcodes in the specified image file.

Syntax

int DBR_DecodeFile(
        const char* pFileName, 
        const pReaderOptions pOption,
        pBarcodeResultArray *ppResults
);

Parameters

pFileName
A string defining the file name.
pOption
A structure defining the barcode reader options.
ppResults
A structure containing barcode results.

Return Value

Zero if the function completed successfully; otherwise nonzero.

Remarks

The file to read needs to be an image in the formats BMP, JPG, PNG, TIFF or PDF.

If your barcodes are from PDF files, DynamicPdf.dll and DynamicPdfx64.dll are mandatory.

Example

ReaderOptions optionn = {0}; 	
pBarcodeResultArray pResult = NULL;
option.llBarcodeFormat = (OneD | QR_CODE | PDF417 | DATAMATRIX);	//Expected barcode types to read.
option.iMaxBarcodesNumPerPage = 100;	//Expected barcode numbers to read.

int iErrorCode = DBR_DecodeFile("C:\\test.bmp", &option, &pResult);

See Also

C > Structs > ReaderOptions
C > Structs > BarcodeResultArray
C > Function > DecodeFileRect
C > Constant > BarcodeFormat
C > Constant > Error List