A Summary by Function of XEDIT Subcommands and Macros

The following chart lists XEDIT subcommands by the tasks you may want to do.

Table 1. Start and Stop Editing, Control Screen, Files, Keys
Task XEDIT Subcommand Description
Control file characteristics SET BFSLine Control the translation between records and byte stream for BFS files.
SET FMode Change the file mode of the current file.
SET FName Change the file name of the current file.
SET FType Change the file type of the current file.
SET LRecl Define new logical record length.
SET NAMetype File IDs are in CMS format (fn ft fm) or in BFS format (pathname).
SET PACK Control whether the editor packs a file when writing it to a disk.
SET PName Change the BFS path name of the current file.
SET RECFm Define record format: fixed, variable, fixed packed, variable packed.
SET SIDcode Insert string into every line of the update file.
SET TRunc Define truncation column (last column for data) as the nth column or * (logical record length).
Control keys SET APL Inform the editor and CMS whether APL characters are to be used.
SET BRKkey Control whether CP breaks in when BRKKEY is pressed.
SET ENTer Define or remove a meaning for the ENTER key.
SET PAn Define or remove a meaning for a hardware attention key.
SET PFn Define or remove a meaning for a hardware program function (PF) key.
SET TEXT Inform the editor and CMS whether text characters are to be used.
Control Message Display CMSG Display a message on the command line.
EMSG Display a message in the message area and possibly sound the alarm.
MSG Display a message in the message area.
SET MSGLine Define position of message line and the number of lines a message may expand to.
SET MSGMode Control whether messages are displayed and whether all messages are full length.
SET Verify Control whether changed lines are displayed (in the message area) and optionally control whether data is displayed in hexadecimal or EBCDIC and what columns are displayed.
Control screen layout SCALE (prefix) Display scale at line where entered.
SET COLOR Specify colors for various screen fields and, optionally, highlighting and other values. Note, this option may be specified as COLOR or COLOUR.
SET CMDline Control the position of the command line.
SET CURLine Define position of the current line on the screen.
SET MASK Control contents of mask (characters that prefill the new line).
SET MSGLine Define position of message line and the number of lines a message may expand to.
SET NUMber Control whether line numbers are displayed in the prefix area.
SET PREfix Control display of the prefix area or define a synonym for the prefix subcommand.
SET SCALe Control the position of the scale.
SET SCReen Controls how many horizontal or vertical screens are displayed; you can edit multiple files or multiple views of the same file.
SET TABLine Control the position of the tabline (showing a T at each tab stop).
SET TERMinal Control whether the terminal is used in line mode or full-screen mode.
SET TOFEOF Control whether notices (Top of File, End of File, Top of Range, End of Range) are displayed.
TABL (prefix) Display the tabline (showing a T at each tab stop) at the line where entered.
SET Verify Control whether changed lines are displayed (in the message area) and optionally control whether data is displayed in hexadecimal or EBCDIC and what columns are displayed.
Edit new or existing file Xedit (CMS command) Edit new or existing file.
Xedit (subcommand) Edit another file.
End editing session CANCEL Stop editing all files. If the QUIT subcommand is defined to perform a protected QUIT, for changed file(s) you receive warning message(s) and must enter QQuit to quit without saving changes.
FILE Stop editing, saving all changes.
PF3 Initial setting: End editing session. (Same as QUIT)
QUIT End editing session of the current file. If the QUIT subcommand is defined to perform a protected QUIT, for changed file(s) you receive warning message(s) and must enter QQuit to quit without saving changes.
Get Help Help Display online help menu.
PF1 Initial setting: Display online help menu.
Save file on disk; stay in edit SAVE Write the file on disk (saving the file with all changes) without ending the editing session.
SET AUtosave Controls the number of alterations required before the editor automatically saves the file.
Transmission of data PA2 Initially assigned as the NULL key.
SET FULLread Control whether XEDIT and CMS recognize 3270 null characters in the middle of screen lines.
SET NONDisp Define a character to XEDIT and CMS that is used in place of nondisplayable characters.
SET NULls Control whether trailing blanks are written to the screen as blanks or as nulls.
SET REMote Control whether XEDIT removes nulls and combines some data to compress it.
with insert key You can use any key defined as NULL key instead of entering SET NULLS ON.
Table 2. Editing Commands
Task Editing Command Description
Add text into lines CAppend Add text at the end of the current line.
CInsert Insert text in the current line before the column pointer. (Position the column pointer with CLocate before inserting text.)
PA2 Allow use of the insert key on an IBM 3270 keyboard to insert characters in a line.
SET NULls ON Allow use of the insert key on an IBM 3270 keyboard to insert characters in a line.
Add lines A (prefix) Add one or more lines after the line where entered.
Add Add one or more lines after the current line.
I (prefix) Add one or more lines after the line where entered.
Input Insert one specified line after the current line or enter input mode.
PF2 Initial setting: Add a line after the line pointed to by the cursor.
POWerinp After the current line, enter power input mode (continuous typing – enter text without regard for line breaks).
SI (Structured Input) After the current line, continuously add lines, automatically indenting to align.
SI (prefix) (Structured Input) Continuously add lines, automatically indenting to align.
Change case of letters LOWercas Change uppercase to lowercase, from current line to optional target.
SET CASE Control whether characters you enter are translated to uppercase or left as mixed case and whether capitalization affects searches (Respect) or not (Ignore).
SET TRANSLat Control uppercase translation of specified characters (when keyboards support some non-English characters).
UPPercas Change lowercase to uppercase from the current line to an optional target.
Change data ALter Change a single character in one or more lines to another (character or hex).
Change Change a string in one or more lines. Strings need not be equal length. If new string is omitted, a null string is assumed.
COVerlay Replace character(s) one for one in the current line, starting at the column pointer. Blanks in the text you enter do not overlay data.
CReplace Replace character(s) one for one in the current line, starting at the column pointer. Blanks in the text you enter do overlay data.
Overlay Replace character(s), starting at column one or at the first tab column (if SET IMAGE ON is in effect). Blanks in the text you enter do not overlay data.
PF6 During SChange (Selective Change), press PF5 to locate the string and then PF6 to change the string.
Replace Replace the current line with specified text, or delete the current line and enter input mode.
SCHANGE (Selective Change) After a Change or a CLocate subcommand, find (with PF5) occurrences of a string and selectively change (with PF6) them throughout a file.
Column pointer commands CAppend Add text at the end of the current line.
CDelete Delete character(s) from the column pointer to an optional column-target.
CFirst Move the column pointer to the beginning of the line (or zone).
CInsert Insert text in the current line before the column pointer.
CLAst Move the column pointer to the end of the line (or zone).
CLocate Move the column pointer to the column-target.
COVerlay Replace character(s) one for one in the current line, starting at the column pointer. Blanks you enter do not overlay data.
CReplace Replace character(s) one for one in the current line, starting at the column pointer. Blanks you enter do overlay data.
Copy lines to another place in same file C, CC (prefix) Copy line(s) to another place in the same file. Position copied lines with the P or F prefix subcommand.
COpy Copy line(s), starting with the current line, to a specified location in the same file.
F (prefix) With C (prefix), position copied line(s) following the line where entered.
P (prefix) With C (prefix), position copied line(s) preceding the line where entered.
Copy lines under original lines DUPlicat Duplicate line(s) one or more times under original line(s).
'', '' '' (prefix) Duplicate line(s) one or more times under original line(s).
Delete or recover deleted data CDelete Delete character(s) from the column pointer to an optional column target.
D, DD (prefix) Delete one or more lines where entered.
DELete Delete line(s) from the current line to an optional target.
Replace Delete the current line and enter input mode.
RECover Recover deleted line(s), inserting them before the current line.
Double-Byte Character Set (DBCS) data SET ETARBCH Define an extended arbitrary character for use in Double-Byte Character strings.
SET ETMODE Control whether XEDIT recognizes DBCS strings.
Exclude Lines or Display Subset of Lines ALL Display a collection of lines containing a specified target for editing; excludes other lines.
S (prefix) Show line(s) you have excluded with the X prefix macro.
SET DISPlay Display set(s) of lines having the same selection level (set with SET SELect).
SET RANge Define a new top and bottom for file. Only lines within the range are displayed and subcommands (except FILE and SAVE) affect only these.
SET SELect Assign a selection level to line(s).
SET SHADow Control whether shadow lines (reporting number of lines not shown) are displayed.
Type Display line(s), from the current line to the target.
X, XX (prefix) Exclude one or more lines from display.
Hexadecimal related ALter Change a single character in one or more lines to another (character or hex) that may not be available on your keyboard.
HEXType Display line(s) from the current line to an optional target in hex and EBCDIC.
SET HEX Control whether you can specify targets and string operands in hexadecimal.
SET Verify Control whether changed lines are displayed (in the message area) and optionally control whether data is displayed in hexadecimal or EBCDIC and what columns are displayed.
Invoke input mode Input Insert a specified line after the current line or enter input mode.
POWerinp Start continuous typing input mode after the current line — you can enter text without regard for line breaks.
Replace Replace the current line with a specified line, or delete the current line and enter input mode.
SI (Structured Input) After the current line, continuously add lines, automatically indenting to align.
SI (prefix) (Structured Input) Continuously add lines, automatically indenting to align.
Move column pointer CFirst Move the column pointer to the beginning of the line (or zone).
CLAst Move the column pointer to the last position of the line (or zone).
CLocate Search for the column-target, starting at the column pointer, and move the column pointer (and line pointer, if SET STREAM ON) to the target.
Move cursor CURsor Move the cursor to a specified position on the screen and optionally assign a priority to this position.
PF12 Initial setting: Move cursor from the file line to the command line or from the command line to the last position it was in the file.
Move data horizontally on the screen COMPress Replace blank (or filler) characters with tabs from the current line to an optional target; prepares line(s) to move horizontally with EXPAND.
EXPand Position data in new tab columns without retyping.
SHift Move data left or right. Data loss is possible.
<, << (prefix) Shift one line or a block of lines one or more columns to the left.
>, >> (prefix) Shift one line or a block of lines one or more columns to the right.
Move lines to another place in file F (prefix) With M (prefix), position the moved line(s) following the line where entered.
M, MM (prefix) Move one line or a block of lines to another position in the file. Position the moved line(s) with the P or F prefix subcommand.
MOve Move line(s), starting at the current line, to a new position in the file.
P (prefix) With M (prefix), position moved line(s) preceding the line where entered.
Move screen horizontally LEft Display data a specified number of columns to the left of column one.
PF10 Initial setting: Display data in columns further to the right or left than currently shown on the screen. Press the key again to return to the original view.
RGTLEFT Display data in columns further to the right or left than currently shown on the screen. Reenter the command to return to the original view.
RIght Display data a specified number of columns to the right of the last column shown on the screen.
SET Verify Control whether changed lines are displayed (in the message area) and optionally control whether data is displayed in hexadecimal or EBCDIC and what columns are displayed.
Move screen vertically or move line pointer BAckward Scroll one, an optional number, or * screens toward Top of file.
Bottom Scroll to bottom of file (or range).
Down Move line pointer a specified number of lines toward End of File.
FOrward Scroll one, a specified number, or * screens toward End of file.
Next Move line pointer n lines toward End of File.
PF7 Initial setting: Scroll one screen toward Top of file.
PF8 Initial setting: Scroll one screen toward End of file.
TOP Scroll to Top of File line (or top of range).
Up Move line pointer a specified number of lines toward Top of File.
/ (slash) (prefix) Make line where entered the current line (and optionally move the column pointer under the column number specified).
all targets Targets are included in various subcommands, such as Locate.
Name a line SET Point Define or remove symbolic name for current line.
.xxxx (prefix) Assign .xxxx as a symbolic name at the line where entered (and delete .xxxx as a symbolic name for another line if already defined).
Number file lines RENum Renumber line numbers of VSBASIC or FREEFORT files.
SET SERial Control whether serial identification is added to the file and the format of serial identification.
Prefix subcommands, macros and canceling them A Add one or more lines after the line where entered.
C Copy line(s) to another place in the same file.
D Delete one or more lines where entered.
E Extend a logical line by one or more virtual lines where entered.
F Position moved or copied line(s) following the line where entered.
I Add one or more lines after the line where entered.
M Move one line or a block of lines to another position in the file.
P Position moved or copied line(s) preceding the lines where entered.
RESet (entered at command line) Cancel pending prefix subcommand or macro.
S Show line(s) you have excluded (for example, with the X prefix macro).
SCALE Display the scale at the line where entered.
SI (Structured Input) Continuously add lines, automatically indenting to align.
TABL Display the tabline (showing a T at each tab stop) at the line where entered.
X Exclude one or more lines from display.
.xxxx Assign .xxxx as a symbolic name at the line where entered (and delete .xxxx as a symbolic name for another line, if already defined).
< Shift one line or a block of lines one or more columns to the left.
/ (slash) Make the line where entered the current line (and optionally move the column pointer under the column number specified).
> Shift one line or a block of lines one or more columns right.
" (double quotation mark) Duplicate line(s) one or more times under original line(s).
Repeat or retrieve command PF6 Initial setting: Display previously entered commands at the command line. Press ENTER to reexecute or type over to change and then press ENTER.
PF9 Initial setting: Reexecute the last entered subcommand, macro, or command.
REPEat Advance line pointer and reexecute the last subcommand.
&(Ampersand) Enter before the subcommand to keep the subcommand displayed at the command line. Press ENTER to reexecute or type over to change and then press ENTER.
= (Equal sign) Reexecute the last subcommand entered, or, with an optional subcommand, execute a specified subcommand and then reexecute the last one.
? (Question Mark) Redisplay the last entered command at the command line. Press ENTER to reexecute or type over to change and then ENTER.
Search for data ALL Display all lines containing a specified target and only those lines.
CLocate Search for column-target, starting at the column pointer.
Find Search for the line that starts with a specified text. Only nonblank characters specified are checked against the file.
FINDUp Search backward for the line that starts with a specified text. Only nonblanks in a specified text are checked against the file.
Locate Search for a target, starting with the line after the current line. With an optional subcommand operand, it executes the subcommand after finding the target.
NFind Search for the line that does not start with a specified text. Only nonblanks in specified text are checked against the file.
NFINDUp Search backward for the line that does not start with a specified text. Only nonblanks in a specified text are checked against the file.
PF5 Initial setting: Locate a string for which you have typed a CLocate or Change command (part of Selective Change).
Search related COUnt Count the number of times a string occurs in a file, starting at the current line.
SET ARBchar Turn on and optionally define or turn off an arbitrary character so you can specify it in a target definition for a string.
SET CASE Control whether characters you enter are translated to uppercase or left mixed case and whether capitalization affects searches (Respect) or not (Ignore).
SET HEX Control whether you can specify targets and string operands in hexadecimal.
SET IMage Control how the editor treats tabs and backspaces.
SET RANge Define a new top and bottom for file, displaying only lines within this range; commands operate only on these lines.
SET SCOPE Control whether the editor operates on all lines or on only those displayed (when displaying a subset of lines, as with ALL).
SET SPAN Control whether a string target must be in one line to be found or can span lines and optionally whether blank(s) separate consecutive lines temporarily concatenated during a search.
SET STAY Control whether the line pointer moves when the search is unsuccessful. (With SET WRAP ON, the line pointer does not move after an unsuccessful search.)
SET STReam Control whether the editor searches the entire file or only the current line for column target.
SET VARblank Control whether the number of blanks between words is significant during a search.
SET WRap Control whether the editor wraps around the file if the end of file or range is reached during search.
SET Zone Define starting and ending columns scanned during a search.
SET operands MODify Display SET subcommand and current operand values at the command line. To change: type over values and press ENTER.
Query Display current values of editing options in the message area.
SET Change settings of various editing options.
STATus Display SET subcommand options and current settings or create a macro containing these settings.
Sort SORT Sort from current line to a target, in ascending or descending order, according to specified sort columns.
Split or join lines Join Combine lines at the column pointer, cursor, or specified position, or insert a string before joining lines. Optionally remove leading blanks from the line being joined.
MErge Combine two sets of lines (side by side).
PF11 Initial setting: Split a line at the cursor or join two lines if the cursor is at the end of the text.
SPlit Split line: optionally at column pointer, at cursor, or at specified position(s). Optionally, add leading blanks to a new line matching those in the original line.
SPLTJOIN Split a line at the cursor or join two lines if the cursor is at the end of the text.
Tab related COMPress Replace blank (or filler) characters with tabs from the current line to an optional target; prepares line(s) to move horizontally with EXPAND.
EXPand Position data in new tab columns without retyping.
MODify TABS Display at the command line the SET TABS subcommand and columns of tab stops. To change: type over settings and press ENTER.
PF4 Initial setting: Tab key.
SET ENTer TABKEY You can define the ENTER key as the TAB key or remove a previously defined meaning for the ENTER key.
SET FILler Define the filler character the editor uses when you issue EXPAND.
SET IMage Control tabs and backspaces.
SET PAn TABKEY You can define a PA key as the TAB key or remove a previously defined meaning for a PA key.
SET PFn TABKEY You can define a PF key as the TAB key or remove a previously defined meaning for a PA key.
SET TABLine Control the display of the tabline. (The tabline depicts a T at each tab stop.)
SET TABS Define logical tab stops.
TABL (prefix) Display tabline (depicting a T at each tab stop) at the line where entered.
Transfer data between files GET Copy all or part of another file after the current line.
PUT Store line(s) in a temporary file (until inserted to another file with GET) or into a new or existing file. Lines are put at the end of the existing file.
PUTD Copy line(s) to another file, deleting them from the original file. Lines are copied into a temporary file (until added to a file with GET) or into a new or existing file.
Truncation related SET SPILL Control whether data is truncated or spilled onto new lines after certain subcommands and whether the editor splits a word between lines if spilled.
SET TRUNC Define truncation column (last column for data) as the nth column or * (logical record length).
Table 3. Identify or Issue Commands
Task Issue Command Description
Identify subcommand, macro, synonym COMMAND Execute a subcommand without checking for a macro or synonym.
MACRO Execute as a macro without checking for a subcommand or synonym.
SET LINENd Control whether the editor recognizes a character as line-end and which character is recognized.
SET MACRO Control the order in which the editor searches for subcommands and macros.
SET PREFIX Synonym Assign a synonym for a prefix subcommand.
SET SYNonym Assign a synonym or control whether the editor looks for synonyms.
Issue command to CMS or CP CMS Issue a command to CMS for execution or have the editor enter CMS subset mode.
CP Issue a command to CP for execution.
SET IMPcmscp Control whether XEDIT passes unrecognized subcommands to CMS and CP for execution.
Table 4. Macro Commands
Task Macro Command Description
Used in macro writing CMSG Display a message on the command line.
EMSG Display a message in the message area and possibly sound the alarm.
EXTract Get information about internal XEDIT variables or file data.
LOAD Read a file into storage from the profile.
MSG Display a message in the message area.
PARSE Scan a stacked line of macro to check the format of its operands.
PREServe Save various XEDIT settings. You can then change settings and later return them to what they were before with RESTore.
PURge Remove a macro from virtual storage.
READ Put data in a console stack (LIFO) from the terminal.
REFRESH Display the screen as of the current moment in processing.
RESTore Change settings back to what they were when you entered PREServe.
SET ALT Change alteration count (in the top line of file information).
SET CTLchar Define a control character that specifies color, highlighting, and other features for parts of a reserved line.
SET LASTLorc Define contents of the LASTLORC (last locate or change) buffer.
SET PENDing Control execution of a prefix macro and status of the screen during execution.
SET RESERved Reserve a specified line the editor cannot use or release a reserved line.
SET = Put a string (subcommand or macro) into equal (=) buffer. (You can then execute this subcommand with the = subcommand.)
SOS Specify functions for screen operation simulation.
STAck Put all or part of line(s) from the current line to optional target in console stack.
STATus Display SET subcommand options and settings or create a macro containing these settings.
SUPerset Improves performance by allowing multiple SET options to be specified in the same subcommand.
TRAnsfer Put specified editing variables in a console stack for use by a macro.
Table 5. Typewriter Terminal Commands
Task Command Description
Used on typewriter terminals LPrefix Simulate writing in the prefix area of the current line.
SET COLPtr Control whether the column pointer is displayed.
SET ESCape Define a character that lets you enter subcommands while in input mode.