OPTIONS Statement Method

You can only specify one numeric file format for all unformatted file unit numbers using this method unless you also use one of the environment variable methods or OPEN statement CONVERT keyword method.

You specify the numeric format at compile time and must compile all routines under the same OPTIONS statement /CONVERT=keyword qualifier. You could use one source program and compile it using different DF commands to create multiple executable programs that each read a certain format.

The FORT_CONVERTn environment variable method, FORT_CONVERT.ext or FORT_CONVERT_ext environment variable method, and the OPEN statement CONVERT keyword method take precedence over this method. For instance, you might use the FORT_CONVERTn environment variable or OPEN CONVERT keyword method to specify each unit number that will use a format other than that specified using the DF option method. This method takes precedence over the DF /convert:keyword compiler option method.

You can use OPTIONS statements to specify the appropriate floating-point formats (in memory and in unformatted files) instead of using the corresponding DF command qualifiers. For example, to use VAX F_floating and G_floating as the unformatted file format, specify the following OPTIONS statement:

  OPTIONS /CONVERT=VAXG

Because this method affects all unit numbers, you cannot read data in one format and write it in another format, unless you use it in combination with one of the environment variable methods or the OPEN statement CONVERT keyword method to specify a different format for a particular unit number.

For more information, see the OPTIONS statement.