Bar2D2f2

int WINAPI Bar2D2f2(HDC hDCref,LPSTR bufin,LPSIZE lps,LPSTR szFileName);

where

hDCref is a handle to a reference device context used to generate a bitmap image. If this handle is passed as NULL then the current screen device context is used.

bufin is a pointer to a null-terminated string containing the barcode data. (Group 2 calls cannot include ASCII 0 in a data stream.)

lps is a pointer to a SIZE structure contain the desired bitmap dimensions in pixels.

szFileName is a pointer to a null-terminated string containing the fully qualified file name into which the barcode image will be stored. (This may be obtained from a dialog by calling ImageFileName().)

Calls to Bar2D2f2 copy an image of the barcode to the file pointed to by szFileName, using the barcode data in the string pointed to by bufin and the properties specified in the embedded BARCODE2D structure. The call returns an error code in the event of an error, otherwise it returns 0.

The Bar2D2f2 function generates a bitmap-type barcode image suitable for reproduction on the hDCref device context at the size specified in the lps size. This function does not generate metafile picture files.

The szFileName string must contain the full pathname of the file required, including one of the permitted file extension which specify the file type. The allowed extensions are those specified for the Bar2D2f calls except that .WMF files are not permitted.

Note that graphic files based on bitmaps should have a target resolution specified by calling SetBitmapScale() before saving the file.

 

More:

ImageFileName