SaveResults - save the results to an XML file
Overview
.net/ocx: Object.SaveResults (file)
com: Object. SaveXMLResults (file)
dll: mtSaveResults (hbarcode, file)
Parameters
hBarcode Handle to an instance of the barcode toolkit (dll only).
file Path to the xml or csv file to be created.
Return Value
1/True on success and 0/False on failure.
Remarks
SaveResults saves the current set of results to an XML or CSV file.
The outputFile format is determined by the file extension (csv or xml).
The CSV fields are as follows:
Folder – location of image file
File Name
Count – number of barcodes found in image
Index – Index for this bar code (1,2,3 etc or -1 is no barcode found).
Error – Error number
ID – as specified in an xml input file for image or folder (see ProcessXML )
Value – value of barcode
Type – type of barcode
Hits – hit count for this barcode
Page – page number in image
Direction – ScanDirection mask value for this barcode
TopLeftX – x position for top left
TopLeftY – y position for top left
BottomRightX – x position for bottom right
BottomRightY – y position for bottom right
The XML output format contains the same information as the CSV format, but arranged in the following way:
<xml version=’1.0′ encoding=’iso-8859-1′>
<SoftekBarcode>
<Result>
<Folder>location of image file</Folder>
<FileName>name of file</FileName>
<Count>number of barcodes</Count>
<Error>error number</Error>
<ID>id as specified in an xml input file for image or folder (see ProcessXML)</ID>
Repeated for each barcode found in image
<Barcode>
<Value>value of barcode</Value>
<Type>type of barcode</Type>
<Hits>score</Hits>
<Page>page number</Page>
<Direction>ScanDirection mask value for this barcode</Direction>
<TopLeftX>x position for top left</TopLeftX>
<TopLeftY>y position for top left</TopLeftY>
<BottomRightX>x position for bottom right</BottomRightX>
<BottomRightY>y position for bottom right</BottomRightY>
</Barcode>
</Result>
</SoftekBarcode>
</xml>
Win32 dll declarations:
VB.Net:
Private Declare Function mtSaveResults Lib “SoftekBarcode” (ByVal hBarcode As System.IntPtr, ByVal strOutputFile As String) As Short
Visual C++:
extern “C” {
int __stdcall mtSaveResults(HANDLE hBarcode, LPCSTR filePath);
}