srepw: Running a Sculptor report program


srepwc progname [param_file [arguments]…]

When a report program (one that contains !report sections) has been successfully compiled with the compiler scc, the run time interpreter srepwc is used to run the program.


The name of the compiled program. The compiled form of the source code bears the same name (progname) as the source file, but has a .q extension rather than a .r extension. Inclusion of the .q extension in the command line is optional.


Specifies the printer parameter file to be used. Printer parameter files are stored in the directory $SCULPTOR/print. If no printer parameter file is specified, the file named printer is used. If output is to be directed to the screen, use the file pterm (if pagination is required) or nullp (no pagination).

If a printer parameter file is specified by means of a ppf = clause in the run report command which calls the report from within the program, then that parameter takes precedence over the one specified in the call to srepwc.


Command line arguments may be sent to the program, as in this example:

srepwc stkcheck hplaser1 95 ABCD

The arguments may be accessed within the program by means of the subscripted Sculptor system variable sys.Arg. In the example above,

sys.Arg[1] is “srepwc”,
sys.Arg[2] is “stkcheck”,
sys.Arg[3] is “hplaser1”,
sys.Arg[4] is “95” and
sys.Arg[5] is “ABCD”.

Note that the space character denotes the end of an argument. In order to send an argument which contains a space, enclose it in double quotes.

It is recommended that only a few simple arguments are passed on the command line, as some operating systems permit only a short command line. Storing information in a file is a better way to pass it between two Sculptor programs.


The run report command can send output to a file or directly to the printer.

See Control sequences for details of the forms used to define control sequences for use with Windows.

Rich text print manager

To create a rich text format file from the output, use the printer parameter file winrtf.p. The resulting file may be loaded and viewed by programs such as NotePad and Microsoft Word, the program to be used being specified in Section 1 (NAMES) of the printer parameter file. If no file name is specified in the run report command which calls the report, Sculptor creates a temporary file.

Sculptor print manager

If any parameter file other than winpm.p (Windows Print Manager) or winrtf.p (Rich Text Print Manager) is used, the report is compiled for use with the Sculptor Print Manager.

Other versions of srepwc

The following additional versions of srepwc are available:


Used to help debug programs which have been compiled with the -d option. srepwcd is executed automatically by the Sculptor debug program scdebug, which allows source code to be viewed as the program runs. Other features include single stepping of commands, breakpoints, and examination of variable values and of the function stack. srepwcd is intended for automatic use by scdebug only, and should not be used to run programs directly.

The $SCULPTOR/app directory

The directory $SCULPTOR/app may be used to store compiled programs. If the progname begins with a colon (:) the program is loaded from $SCULPTOR/app.


srepwc :data1/supplies

Loading a program from a remote server

The run time interpreter srepwc can load a program from a remote server which is running one of the Sculptor server programs kfserver and kfservnt. The full path to the object code file (.q extension) should be specified. See Running Sculptor programs on a server.


srepwc myserver:/usr/myapp/myprogram


  • The run time interpreters srepw and srepwd should be treated as obsolescent.


Compiling a Sculptor program

Running a Sculptor screen form program

The Sculptor program suite


Printer parameter files


run report