This function assigns the content of an IMAGE variable to a file.
Important: If the content of the image variable is the Visual Adelia IMAGE object's BITMAP property or the result of the VaToolBxLoadBitmap function, use the VaToolBxSaveBitmap function to create a .bmp file.
Context
Windows client,
Windows server,
Java client,
Java server,
Adelia Web client,
Adelia Cloud client.
Parameters
IMAGE |
ImageVar |
Variable with the content. |
ALPHA(n) |
FileName |
Name of the file that is to receive the content of ImageVar. The file is created if it does not already exist, or replaced if it does. |
NUM_BIN_2 |
ReturnCode |
Return code for the operation. 0 Operation completed successfully. -1 Cannot open file. -2 Cannot read file. -3 Invalid IMAGE variable. |
Example
FileName = 'C:\temp\document.doc'
CALL_DLL 'VATOOLBX.DLL' 'VaToolBxImageToFile' ImageVar FileName ReturnCode
* => the file C:\temp\document.doc received the content of ImageVar.
Click below for more details about the following elements:
The VaToolBxLoadBitmap function
The VaToolBxSaveBitmap function
The IMAGE basic graphical object
List of the VaToolBx functions by topic