WRITE PICTURE FILE

4D - Documentation   Français   English   German   Spanish   4D v11 SQL, Command Theme List   4D v11 SQL, Command Alphabetical List   4D v11 SQL, Constant Theme List   Back   Previous   Next

version 11 (Modified)


WRITE PICTURE FILE (fileName; picture{; codec})

ParameterTypeDescription
fileNameAlphaName or full pathname of the file to write,
or empty string
picturePicturePicture field or variable to write
codecStringPicture Codec ID

Description

The WRITE PICTURE FILE command allows you to save the picture passed in the picture parameter in the defined codec to disk.

You can pass in fileName the full pathname to the file to create, or a file name only. If you just pass the file name, the file will be located next to the database structure file. Under Windows, the file extension has to be indicated.

If an empty string ("") is passed in fileName, the standard Save file dialog box is displayed and the user can indicate the name, location and format of the file to create.

You will pass in picture the picture variable or field which contains the picture to save on disk.

The optional codec parameter can be used to define the format in which the picture will be saved. A Codec can be an extension (for example, ".gif"), a Mime type (for example "image/jpeg") or a 4-character QuickTime code (for example "PNTG"). You can get a list of available Codecs via the PICTURE CODEC LIST command.

If the codec parameter is omitted, the picture file is created with a PICT format.

If the command is executed successfully, the system variable Document contains the full pathname to the file created and the system variable OK is set to 1. Otherwise, OK is set to 0.

See Also

PICTURE TO BLOB, PICTURE TYPE LIST, Pictures, READ PICTURE FILE.


4D - Documentation   Français   English   German   Spanish   4D v11 SQL, Command Theme List   4D v11 SQL, Command Alphabetical List   4D v11 SQL, Constant Theme List   Back   Previous   Next