Published By | Date | Version | Knowledge Level | Keywords |
---|---|---|---|---|
Sprezzatura Ltd | 01 DEC 1992 | 3.0+ | EXPERT | CMD, WINDOW_COMMON% |
Dave Brown of Doorcraft Manufacturing writes "I was poking around in CMD and found the list of primitives it uses (REAL.ACCOUNTS and LIST.USERS are very helpful). There's too many commands to list here, and I've already figured out the use of some, but a few have me curious: STROKES, POST.APP.VIEWER, TMARK, SOURCE.IDS.CVT, GL, USER.NOVE, and DEST.DEFLT.". So for Dave (and others out there who might be curious), we present below the definitive guide to CMD - the system subroutine used by a large number of command windows. Note that to make use of this subroutine it is normally necessary to have Window_Common% loaded.
Branch | Windows Used By | Description |
---|---|---|
ATCH.OF | ATTACHTABLE DETACHTABLE VERIFYLH | Looks at @Record< 2 > and provides a popup of tables at that location for the current account. Multiple selections can be made and are returned in @Ans. If no location is specified in @Record<2> then the default location is used. |
ATCH.PV | ATTACHTABLE SETALIAS | Takes the location in WC_Is% and loads WC_REGISTER%(1) with a dynamic array of five fields with layout as follows: < 1 > Location name < 2 > Dos path to location < 3 > Multi-valued list of tables at location < 4 > Filing system used by location (E.G. RTP57) < 5 > File handle for location, combine with < 4 > for file variable. |
DEF.VOLUME | LISTVOL LISTVOLUME MAKEDICT MAKETABLE SETALIAS | Returns the default data volume in @Ans. |
DELETEREC.POST | DELETEROW VERIFYLH | Adds "(" to the beginning of @Record<4> so that when @Record is executed as a TCL statement from a collector window (REVMEDIA passim) the options will be bracketed. |
DEST.DEFLT | IMPORT.TEMPLATE | Returns the corresponding multi value from @Record<3>. |
DTCH.SAVE | DETACHTABLE | Used to abort a save if @Record<2> and <3> both contain information. |
ESC.TO.NULL | EDIT.ANOTHER | Used on a post window hook to set @Pseudo to null if escape was hit in the collector window. |
FFE.REC.OPT | FORM | Takes WC_Register%(2) as the title and WC_Register%(3) as the table variable and displays a popup of rows in the table. |
FFE.SAVE | FORM | Massages @Record to ensure that when it is executed as a TCL statement from the collector window it behaves properly. |
FFE.SETUP | Unused | Loads WC_Datafile% and @Record with REPORTS and opens WC_Src_File% to REPORTS. |
FFE.WIN.POST | FORM | Uses the contents of WC_Is% to load the form into WC_Register%(1), the datafile into (2) and the file variable into (3). |
FORMSPEC.SAVE | MAKEFORM.PARMS | Sets @Record<1> to 1. |
FREEFORM.SAVE | Unused | Sets @Record<1> to 1 |
GL | GETLIST | If a select list is active produces a warning message that the select list will be overwritten by the current operation. The user is asked whether they wish to continue. If they do the select list is cleared. |
LHV.VOL | VERIFYLH | Checks the locations contained in WC_Is% to be valid. If they are not an error message is displayed. |
LIST.ACCOUNTS | COPYTABLE RENAMETABLE SETALIAS | Provides a popup of all applications on the system. |
LIST.USERS | Unused | Provides a popup of all users on the system. |
MACRO.SAVE | Unused | ? |
MACROS | MACROS | Loads @Record with three fields containing 4 value marks space delimited. |
MAKEDICT.PP | SOURCE.WINDOW | ? |
MAKEFORM.READ | Unused | Loads @Pseudo with @Fm concatenated to the window form parameters. |
MAKEFORM.SAVE | MAKEFORM | Calls the form parameters window then returns the form definition in WC_Register%(1) and the form parameters in WC_Register%(10). |
MAKELIST | MAKELIST | Provides a popup of all of the dictionary items for the table in WC_Datafile%. |
MAKEVOC | SETPROGRAM | Adds "(" to the beginning of @Record<4> so that when @Record is executed as a TCL statement from a collector window (REVMEDIA passim) the options will be bracketed. |
ML.FILTER | Unused | Provides a popup of all of the records in the REPORTS table. |
ML.FILTER.TEXT | Unused | Does not work. |
ML.LINE.NUMBER | Unused | Does not work. |
MOVE | COPYTABLE | Prompts the user for a table name to move to. |
PFE.SETUP | WFE | Clears down @Sentence. |
POS3.OPTIONS | LISTDICT LISTVOLUME | Converts spaces and commas to value marks in @Record<3> and surrounds the whole in parentheses. |
POS4.OPTIONS | COMPILEBASIC LISTBASIC | Converts spaces and commas to value marks in @Record<4> and surrounds the whole in parentheses. |
POST.APP.VIEWER | Unused | Used on a post window hook to set @Pseudo to null if escape was hit in the collector window. |
PRESERVE | CUSTOMIZE | Used to provide the Preserve Keys/Fields popup in Customise. |
PU.DISPLAY | MAKEPOPUP | Used to display the current record as a popup in the MAKEPOPUP window. |
REAL.ACCOUNTS | MENU_SECURITY OPENAPPLICATION WINDOW.SECURITY | Provide a popup of all accounts on the system excluding GLOBAL. |
REMAKEFILE | REMAKETABLE | Sets @Record<4> to @Account and @Record<5> to @Record<2>. |
RL.ACCT.NOVE | Unused | For use as an edit pattern - rejects an entry that exists on SYSENV. |
RL.ACCT.VERI | OPENAPPLICATION | For use as an edit pattern - rejects an entry that is not an application. |
RUN.MENU | MENU | Runs the menu named in @Record. |
SETF.OF | SETALIAS | Looks at @Record< 2 > and provides a popup of tables at that location for the account in @Record<3>. One selection can be made and is returned in @Ans. If no location is specified in @Record<2> then the default location is used. |
SETVOLUME | SETVOLUME | Used to create a volume pointer in VOC from the current record. |
SETVOLUME.DL.OPTIONS | SETVOLUME | Used for options on data location prompt. |
SETVOLUME.VALID.VOLUME | SETVOLUME | Used to ensure that @Record<1> contains "VOLUME". If it does not, WC_Valid% is set to 0. |
SFACCT | SETALIAS | Used as an edit pattern to ensure that an entry is an attachable location. |
SFO | SUMROWS | Displays popup of rows in table contained in @Record<2>. |
SOURCE.IDS.CVT | IMPORT.TEMPLATE | Displays popup of rows in table contained in @Record<1>. Allows multiple selections and puts result in @Record<3>. |
STROKES | Unused | Appears not to do anything. |
TMARK | Unused | Converts @Tms to spaces in @Record. |
TRN | BTREE CREATE_TABLE CROSSREV DELETEROW DETACHTABLE FORMULA NAMEVOLUME PROCESS.WINDOW SETPROGRAM SMART.LABEL SOFTKEYS SOURCE.WINDOW XLATE.ENTRY | Closes window if on a runtime version. |
UNMAKEVOC | Unused | Creates popup of all entries in VOC with F1 = "RBASIC" and permits multiple selections, with @Ans containing results. |
USER.NOVE | Unused | For use as an edit pattern - rejects an entry that already exists on SYSENV. |
USER.VERI | Unused | For use as an edit pattern - rejects an entry that is not a user in SYSENV. |
(Volume 4, Issue 7, Pages 12-15)