SaveTiffFileFromClipboard

#include "BITIFF.H"

 

BOOL CALLBACK SaveTiffFileFromClipboard( LPTSTR lpszFileName,
UINT     wCompMode,
BOOL    DisplayDlg)

Description

Saves the bitmap from the Clipboard in the TIFF file lpszFileName. Does all low level calls internally in the DLL. To retrieve the last error, use the TiffErrorString(). The wCompMode must be set to one of the compression types defined in the Document Imaging SDK USER’S GUIDE, page 3-5. The wCompMode is ignored if DisplayDlg is set to TRUE.

The following compression types are defined in BITIFF.H.

Compression type -     TCOMP_NOCOMP               - No compression

                                                TCOMP_PACKBITS             - Packbit

                                                TCOMP_LZW                        - LZW

                                                TCOMP_LZW_DIFF             - LZW with differentiation

                                                TCOMP_CCITTG2                - CCITT Group 3 1D NO EOL

                                                TCOMP_CCITTG31D           - CCITT Group 3 1D

                                                TCOMP_CCITTG32D           - CCITT Group 3 2D

                                                TCOMP_CCITTG4                - CCITT Group 4

                                                TCOMP_JPEG                       - JPEG

 

if the ‘DisplayDlg' is set to TRUE, a dialog box is displayed with the different options to save the bitmap in the Tiff file.

Parameters

LPTSTR

lpszFileName

Path to the TIFF file.

UINT

wCompMode

Compression type.

BOOL

DisplayDlg

Display dialog box. The dialog box is implemented in BiDlgs.dll. If this parameter is TRUE and BiDlgs.dll does not exists, the error code will be TNOBIDLGS.

Additional Information

This example shows how to use the dll when loading statically including the header file. Otherwise if the dll is loaded dynamically, for further information read the “About the difference of static and dynamic library loading” section of the manual.

Return values

TRUE on success, otherwise FALSE.

Requirements

Header :     Declared in BiTiff.h; include BiTiff.h.

Library :    Use BiTIFF.lib.

DLLs :       BiTiff.dll, BiDlgs.dll.

References to related functions

See LoadTiffIntoBitmap(), LoadTiffFileIntoClipboard().