GetFormatList

All Editions image\bltlrgss.gif Related Transactions  image\bltlrgss.gif Example

The GetFormatList transaction returns a list of valid formats for the specified file type.

Type XTYP_REQUEST

Syntax [GetFormatList(fileType)]

Parameter

Data type

Values

Meaning

fileType

WORD

1

8-bit color rasters

 

 

2

bilevel rasters

 

 

4

24-bit color rasters

 

 

8

vectors

 

 

16

multilayer or multipage documents

Reply

Data type

Values

Meaning

count

WORD

0

1 | 2 | 3 | . . .

none

number of formats

defFormatID

WORD

0 | 1 | 2 | . . .

0-based index into the list. See Remarks.

ext

string

one- to three-character text string

default extension

description

string

text string

description of the format

formatID

WORD

File Format IDs

identifier of the format. See Remarks.

Remarks

The defFormatID returned as a reply code is a 0-based index into the list of formats that follows it. That is, if its value is 0, the default format is the first one in the list; if its value is 1, the default format is the second one; and so on.

The last three reply variables (ext, description, and formatID) are repeated for every format in the list. To see a complete list of output formats for your configuration, you could write a program to get the list and print it. Because you have access to this list, you could display a dialog box and permit the user to select the format prior to performing the save.

Release Information

Added in Release 3.70.

See also

Selecting file formats