CImage:SaveTo
The SaveTo method saves the CImage to a file with a new file name. This method does not prompt for the new file name. To prompt, use SaveAs.
bResult = CImage:SaveTo( sPath ) |
sPath is the new file name, including the full path.
On success, this method returns true. If unsuccessful, it returns false.
When using a loop to save multiple images, you may wish to prompt for the text fragment to be used for renaming the files. You can do that for the first image in the loop by using the SaveAs class method to select the path or get a template file name, or by calling the global GetString function. Afer the first image is saved, you can use SaveTo for the remaining images.
Suppose a CImage object I contains an image to be saved with a new file name. The following script does this without prompting for the new filename:
|
-- create a CImage object |
|
-- the new file name |
|
-- Save the image to its new file name |
|
-- do something |
Mira Pro x64 Script User's Guide, Copyright Ⓒ 2024 Mirametrics,
Inc. All Rights Reserved.