SaveAs Method

Description

Saves the ImageFile object as another ImageFile object. Copies its image file and renames it.

This method allows you to specify the new object's image parameters. If specified, the file can be converted from one type to another. The current image file is closed without being saved and the Save As object becomes the active image file. You can optionally display a dialog box that allows the end-user to name the file for the first time or select a file to overwrite.

Syntax

ImageFileObject.SaveAs [imagefile] [, filetype] [, dialogflag]

DataType

String

Remarks

The SaveAs method uses these parts:

Part

Description

imagefile

The destination's ImageFile object name string.

filetype

Image file type to save to.

dialogflag

If True, displays a dialog box that allows the end-user to enter or select a filename and options for saving the file. The default is False.


The SaveAs method filetype argument settings are:

Setting

Description

1

TIFF

2

AWD

3

BMP

4

PCX

5

DCX

6

JPEG


Example

This example saves a file in TIF format.

Img.SaveAs "picture1.tiff", 1

This example opens a Save As dialog box so that the end-user can name the file for the first time or overwrite an existing file:

Img.SaveAs "", 0, True