Additional PRO/5 Command Information for MS-DOS and MS-DOS Networks

Overview

This section contains useful information about additional modes supported or not supported on the MS-DOS Networks version of PRO/5.

Shell Command

The "!" character, in console mode only, allows execution of MS-DOS commands. The following generates a directory of the current directory on drive "C:" by passing all text after the "!" to the current command processor:

!dir c:*.*

PRO/5 does not examine or modify in any way the text following the "!" character.

CISAM

PRO/5 supports an additional file type (called C-ISAM) on systems that provide a library for accessing and manipulating this file type. As of this writing, this file type and the CISAM command are not supported on MS-DOS systems.

FID(0)

If the environment string BBTERM=name exists, then the FID(0) will return this string. You may also use the -t flag. See Invoking PRO/5, Command Line Options for more information.

If you change the standard input and standard output for PRO/5 to anything but the console, then the FID(0) will be the alias "IO." The "IO" device does not support mnemonics.

In all other cases, the FID(0) will be the first ALIAS found that references the device "/dev/con" as a PRO/5 workstation.

HSA()

The HSA() function returns the number of 512-byte sectors available on the referenced disk.

INFO()

Some of the values returned by the INFO() function may be set using the following environment variables:

Env. Variable

Returned In

Description

SHORTID

INFO(3,0)

2 character unique task ID

LONGID

INFO(3,1)

8 character unique task ID

USERID

INFO(3,2)

user login ID

USERDESC

INFO(3,3)

long user name

These are defined in this manner for software generated under the UNIX operating system that might expect this information. Note that under Novell NetWare these values are available from the OS.

RENAME

PRO/5 will attempt to rename a file from one path to another. However, a file cannot be given a new path that goes to a different disk drive than the old path.

If the new file name does not have a path, the path from the original file name is used.

SCALL()

  • The SCALL() function may fail to execute under some conditions without reporting any failure. This occurs when there is not enough memory to load the command processor to perform the execution.

  • It is possible that the system could fail if COMMAND.COM cannot be found.

  • On some releases of MS-DOS, the value returned may not accurately reflect the exit code of the executed command.

  • If you use the SCALL() function and the program invoked includes a .com or .exe extension, then the program is executed using the program environment variable comspec. For example, command.com /cfilename invokes the command file.

TCB(10)

The TCB(10) will return an error code indicating the underlying cause of an error generated in PRO/5 input or output. If the value returned by TCB(10) is positive, the value contains no more information than the ERR variable. If TCB(10) returns a negative number, the ABS() of the value is the actual error code given to the PRO/5 filesystem by DOS.

The value of the TCB(10) function will not change until the application causes another error to occur using I/O. The value of the TCB(10) relates only to errors involving files or devices.

Application code, depending on the values returned by the TCB(10) function, will be highly non-portable as these returned values may change between host operating system releases and/or PRO/5 releases.