Overview | Statement List


关闭文件

Synopsis

FTERM/{PART[options]|TXT,file#}[,IFERR,label:]

Description

This statement closes an active part(s) or scratch file without saving. Options for the PART minor word allow you to either: close all parts or specify a part file name, close all the subassemblies of the part, or close modified part(s) without an error. If you do not use any options with the PART minor word, then the command closes the default work part.

"[options]" is equivalent to: [,all|[,string][,asmbly][,always]]. If you specify the all option, then the use of string, asmbly, or always is invalid. If you use any one or all of string, asmbly, or always then the use of all is invalid. The following are some typical syntax examples of using FTERM.

FTERM/PART[,all][,IFERR,label:]

FTERM/PART[,string][asmbly][,always][,IFERR,label:]

FTERM/TXT,file#[,IFERR,label:]

Parameters

Parameter

Description

PART

Minor word that indicates that the files to be closed are part files.

[options]

Specifies either all or any of the options string, asmbly, or always.

all

Closes all parts in a session without saving. When you use the all option, the string, asmbly, and always options are not available for use.

string

Specifies the name of the part to close. The part name can be a file specification (path and file name). The string can be a variable or a string literal.

asmbly

Closes the current part/specified part and all of its subassemblies.

always

Closes the part(s) without error even if the part(s) were modified.

TXT

Minor word that indicates that the file to be closed is the text file which is currently in the specified scratch file.

file#

The number of the scratch file which is to be closed. Ten scratch file areas are available, therefore, the specified number must be between 1 and 10.

NOTE: GRIP NC CLS files also access scratch file 1. If accessing scratch file 1, you should first check to make sure no other file is there, or that file will be lost. See the example in File Management Statements table.

IFERR,label:

Specifies a label to which the program jumps if an error occurs.


Copyright ©2015 胡君NX二次开发官网(www.UGapi.com) QQ:85585969 All Rights Reserved.