Use FileDefine to create a new file.
FileDefine may also be entered as FileDef[ine], DefineFile, DefFile, or Def[ine].
Required Operands
FILE is the BIM, workstation, PDS, or VSE file to be defined. A file of this name must not already exist.
Optional Operands
TYPE [Supported for BIM, workstation files only.] is the file type, that determines the initial attributes and contents of the new file. File attributes from TYPE can be overridden by using other operands on the FileDefine command. If TYPE is enclosed in parentheses, the file will not have any initial contents. TYPE can be up to 8 characters in length.
For program source files, TYPE is also typically used by the FileCompile command to determine which compiler to invoke.
Host BIM-EDIT, as distributed, provides the following TYPEs.
$DFL Default template.
ASM Assembler program source.
COBOL COBOL program source.
DATA Data.
FORT FORTRAN program source.
JCL VSE, MVS job streams.
PLI PLI program source.
PROC Procedure.
RPG RPG program source.
TEXT Textual material, such as documentation.
BIM-EDIT/XP, as distributed, provides the following TYPEs.
$DFL Default.
ASM Assembler program source.
C C or C++ program source.
CMD Workstation command file or REXX procedure.
COB COBOL program source.
CTL appl. control file.
D Document.
DAT Data.
DOC Document.
FOR FORTRAN program source.
IPF IPF text.
JCL VSE, MVS job streams.
PLI PLI program source.
PRC BIM-EDIT/XP procedure.
RPG RPG program source.
TXT Textual material, such as documentation.
The System Administrator may have added or deleted TYPEs from the above lists.
For BIM files, TYPE is implemented by copying the attributes and text of a template file of name TYPE in the host BIM-EDIT Site or System model directory to the new file.
For workstation files, TYPE is implemented by copying the attributes and text of a template file (see Template files) to the new file.
Default for BIM files: $DFL.
Default for workstation files: the extension part of FILE name, if present. Otherwise, $DFL.
TITLE [Supported for BIM, workstation files only.] is a comment about or description of the file. TITLE can be up to 40 characters in length.
ATTR [Supported for BIM, workstation files only.] is an attribute with site-defined usage -- check with your System Administrator. For program source files, ATTR is typically used by the FileCompile command to determine the nature of the compile. ATTR can be up to 8 characters in length.
AUDIT [Supported for BIM, workstation files only.] Specify ON if file auditing is desired. OFF suppresses file auditing. File auditing allows you to view and undo all modifications to file text, but it also uses considerable disk space and some additional processing time. For BIM files, if the host pre-defined variable MMPAUCTL has been set to 1, only the System Administrator can specify AUDIT=OFF.
CASE [Supported for BIM, workstation files only.] Specify U if characters typed into an Edit session in lower case are to be translated to upper case. Specify M if no translation is to occur.
CHECK [Supported for BIM files only.] specifies whether file is under check out/check in control. Specify ON if editing can be done only on a checked out copy. Specify OFF if file can be edited directly.
LIBDEF [Supported for BIM, workstation files only.] is an attribute with site-defined usage -- check with your System Administrator. LIBDEF can be 8 characters in length. This field is typically used by the FileCompile command to determine how to build job control for a compile job stream.
NULLS [Supported for BIM, workstation files only.] specifies whether the trailing blanks on a line are to be replaced with nulls when displaying the file on a 3270 terminal. ON specifies that trailing blanks will be replaced, while OFF specifies that they will not. When NULLS is on, the 3270 terminal insert mode can be used. However if text is entered to the right of null character(s) on a line, the text ends up shifted left since the nulls are not transmitted to BIM-EDIT.
SEQ [Supported for BIM, workstation files only.] specifies a column range where the EditResequence command places sequence numbers. Enter it in the format xxx-yyy where xxx and yyy are numbers between 1 and the session maximum line width. For example, to place sequence numbers in columns 73 through 80, specify SEQ as "73-80". The SEQ range cannot be wider than 8 columns.
TCOL [Supported for BIM, workstation files only.] specifies a list of columns used for tabbing. Up to 12 tab settings may be specified. They are entered in the format cc-cc-cc. Each setting consists of one to five digits that specify the column where the text will be placed. Tabbing range is from 1 to the maximum line width. Tab columns must be entered in ascending order.
USER [Supported for BIM, workstation files only.] is purely documentary. It can be set to any value. When a file is created, if USER is not specified, USER is set to the log-on USER ID. Typically, this value is used to determine ownership when culling junk files from the directory. It can be up to 8 characters.
ZONE [Supported for BIM, workstation files only.] specifies a column range used by the edit and search commands (such as EditChange, EditCenter, Locate, etc.) if not specified explicitly on the command. For example, the EditChange command will change occurrences of one string to another within the current ZONE only. Enter ZONE in the format xxx-yyy where xxx and yyy are numbers between 1 and the maximum line width. For example, ZONE=1-72 signifies columns 1 to 72. ZONE=5 is the same as ZONE=5-5, ZONE=5-* specifies columns 5 through the maximum line width, and ZONE=-5 is the same as ZONE=1-5.
FINDCOL [Supported for BIM, workstation files only.] specifies a column used by the Find, FindFirst, FindUp, NotFind, and NotFindUp commands if not specified explicitly on the command. Enter FINDCOL as a number from 1 to the maximum line width. For example, the Find command scans forward for a line with a specified string starting in the FINDCOL column.
STAMP [Supported for BIM, workstation files only.] Specify ON if file stamping is desired. OFF turns file stamping off. For BIM files, if the host pre-defined variable MMPSPCTL has been set to 1, only the System Administrator can specify STAMP=OFF.
WRAP [Supported for BIM files (BIM-EDIT release 5.1A and above) and workstation files only. Other file types can still use the Word-wrap feature, but may have to use SessionAlter to activate the feature. BIM files with TYPE=TEXT for which the WRAP value has not been specified are created with Word-wrap on.] specifies if Word-wrap mode is to be active for Edit sessions of this file. Specify "On" or "N[o]" otherwise.
FileDefine sets the last referenced file.
When Valid
The user must have DEF access level for the FILE directory.
Return Codes
OK Successful.
DP File already exists.
NF One of the following:
Directory not found.
TYPE is not valid.
SC Inadequate access level.
Procedure Notes
FileDefine sets the TXM variables to the attributes of FILE.
Examples
Define workstation file DSIV200.C:
=> def dsiv200.c,title='Inventory Summary Report'
Define BIM file GLM2300 as a COBOL file:
=> def GLM2300,cobol,title='print general ledger'
Define a BIM data file named UMDAT with nulls set to off:
=> def umdat,data,nulls=off
Define the BIM COBOL file ESAR030:
=> def esar030,cobol,tcol=8-12-16-40-56