Copyright © 2002-2009 MultiMedia Soft 
Return to index  
 
abmExportBtnImage function 
 
Remarks
Exports the full image of the button into a picture file.
Return value
Value
Meaning
 
 
FALSE
The operation failed
TRUE
The operation was successful
Syntax
BOOL abmExportBtnImage
HWND hWndBtn, 
short nImage, 
LPCTSTR strFilename, 
long nFormat 
); 
 
 
Parameters
Description
hWndBtn
Windows handle associated to the button.
nImage
Numerical value that identifies the image that must be exported. Supported values are the following: 
Mnemonic constant
Value
Meaning
EXPORT_IMAGE_NORMAL
0
The image of the button in normal state.
EXPORT_IMAGE_MOUSEOVER
1
The image of the button when the mouse is over its surface.
EXPORT_IMAGE_PRESSED
2
The image of the button in pressed state.
EXPORT_IMAGE_FOCUS
3
The image of the button when it has the input focus.
EXPORT_IMAGE_DISABLED
4
The image of the button in disabled state.
strFilename
String representing the name of the file that will receive the image in the specified format.
nFormat
Contains information about the export format: the low-order word (lower 16 bits) of this parameter contains the graphical format while, for certain formats, the high-order word (higher 16 bits) of this parameter contains further options relative to the specific graphical format. 
Supported values are the following:  
Mnemonic constant
Value
Meaning
EXPORT_FORMAT_BMP
0
Windows bitmap (BMP)
EXPORT_FORMAT_PNG
1
Portable Network Graphics (PNG)
EXPORT_FORMAT_JPG
2
JPEG (JPG) 
The high-order word of this parameter contains the JPEG compression factor whose range can be in the range 0 (Maximum compression, Low Quality) and 100 (Minimum compression, High Quality). 
Examples below (in magenta the compression factor's value): 
nFormat set to hexadecimal 00500002 will produce a JPEG picture (hex value 0002) with quality 80 (hex value 0050) 
nFormat set to hexadecimal 00200002 will produce a smaller JPEG picture (hex value 0002) but with a lower quality 32 (hex value 0050)
EXPORT_FORMAT_CLIPBOARD
3
The button image is exported into the Clipboard. In this case the strFilename parameter is ignored.
EXPORT_FORMAT_GIF
4
GIF 
The high-order word of this parameter contains the error diffusion flag. 
Examples below (in magenta the error diffusion's value): 
nFormat set to hexadecimal 00010004 will produce an opaque GIF picture (hex value 0004) with error diffusion available (hex value 0001) 
nFormat set to hexadecimal 00000004 will produce an opaque GIF picture (hex value 0004) without error diffusion (hex value 0000)
EXPORT_FORMAT_GIF_TRANSP
5
Transparent GIF 
The high-order word of this parameter contains the error diffusion flag. 
Examples below (in magenta the error diffusion's value): 
nFormat set to hexadecimal 00010005 will produce a transparent GIF picture (hex value 0005) with error diffusion available (hex value 0001) 
nFormat set to hexadecimal 00000005 will produce a transparent GIF picture (hex value 0005) without error diffusion (hex value 0000)
EXPORT_FORMAT_PNG_TRANSP
6
Transparent PNG
 
 
 
 
 
 
 
 
 
Copyright © 2002-2009 MultiMedia Soft 
Return to index