Please enable JavaScript to view this site.

A-Shell Development History

New command AGCMD.LIT may be used to send a TAB(-10,AG_xxx) command from the dot prompt or within a command file (without having to write code and compile it). Useful for experimentation and for inserting simple ATE or other GUI configuration commands in startup command files. Usage:

AGCMD{/switches} <cmd> <params>

<cmd> is the symbolic AG_xxx name (case insensitive, with or without the AG_ prefix), or numeric value of the AG command to execute.

<params> is the remainder of the parameter list as it would be passed in the TAB(-10,AG_xxx) statement, except without the trailing chr(127).

Switches:

Switch

Function

K#

Assign result to CMD/DO variable $KBD#

S

Silent (don't display the command response)

N

No wait (don't wait for any response)

W:#

Wait # seconds for response (overriding default)

 

Examples:

AGCMD WINEXEC,$DEL %ATE%\dsk0\001004\ftpdlx.log

AGCMD WINTITLE,This is the new and improved title

AGCMD SHOWWINDOW 3

AGCMD STATUSLINES,1,0

AGCMD/S 24,cmd.exe,option,"/c ipconfig > ipcfg.lst",,0,1

AGCMD/N PALETTE,3,0,123,207,242

AGCMD/S/K1 BROWSEFOLDER

Note that if neither of the /N or /W:# switches are specified, AGCMD will use the "normal" wait value based on the command itself, ranging from no wait (for commands with no response, e.g. AG_STATUSLINES), to a few seconds (for commands with an immediate response, e.g. AG_GETENV), to unlimited (for commands which require a user response, e.g. AG_WINPTR).

Some commands, however, have a variable response (or lack of), depending on the command parameters. For example, AG_PALETTE has no response when used to set a color, but has a "standard wait time" response when used to retrieve palette info. For these commands, AGCMD defaults to the "standard wait time" (a few seconds). To avoid waiting for a response that won't be coming, use the /N switch (as in the example above).