Sei sulla pagina 1di 3

SAP SCRIPTS

SAP SCRIPTS are used to generate formatted documents which can contain logos,
tables and other formatting objects. And these documents can look like a pre-printed
documents that normal ABAP codes cannot possible. SAP script comprises these
five components:

an editor for entering and editing the lines of a text.


styles and forms for print layout.
the composer as central output module. 4)a

programminginterface 5)several database tables for storing texts,


styles and forms.
Here you will get some SAPSCRIPTS tutorials and Pdf guides todownload.

Sap Scripts Commands Control commands


Comparison between SMARTFORMS and SapScript

SAP SCRIPTS COMMANDS


CONTROL COMMANDS
Details and syntax of control command used in sapscript
The function module OPEN_FORM opens form printing. You must call this
function module before you can use any other form function
(WRITE_FORM, START_FORM, CONTROL_FORM).
You need not specify a form name. If you omit the name, you must use
the function module START_FORM to open a form before starting the
output.
You must end form printing by using the function moduleCLOSE_FORM.
Otherwise, the system does not print or display anything.
Within a program, you can use several OPEN_FORM..CLOSE_FORM pairs.
This allows you to write output to several different spool requests
from within one program.
The function module closes the form opened using OPEN_FORM. The system
executes any terminating processing steps for the last opened form.
You must use this function module to close form printing. Otherwise,
no output appears on printer or screen.
In-between the function modules OPEN_FORM and CLOSE_FORM, you can use
different forms. This allows you to combine several different forms
into one print output. However, you can combine only those forms that
have the same page format.
To switch forms, use the function module START_FORM. If another form
is still open, you must close it first using END_FORM.
If you specify no form name when calling START_FORM, the system
restarts the last open form. If after OPEN_FORM no form was activated
yet, the system leaves the function module with the exception UNUSED.
END_FORM ends the currently open form and executes the required
termination processing. After calling this function module, no more
form is active. For further output, you must start a new form using
START_FORM.
END_FORM does not replace CLOSE_FORM, that is, you must always close
any SAPscript output using CLOSE_FORM
READ_TEXT provides a text for the application program in the specified
work areas.
The function module reads the desired text from the text file, the

text memory, or the archive. You must fully specify the text using
OBJECT, NAME, ID, and LANGUAGE. An internal work area can hold only
one text; therefore, generic specifications are not allowed with these
options.
After successful reading, the system places header information and
text lines into the work areas specified with HEADER and LINES.
If a reference text is used, SAPscript automatically processes the
reference chain and provides the text lines found in the text at the
end of the chain. If an error occurs, the system leaves the function
module and triggers the exception REFERENCE_CHECK.

SMARTFORMS
SMARTFORMS as the SAPScript successor tool is also used to generate formatted
documents which can contain logos, tables and other formatting objects. And this
documents can look like a pre-printed documents that normal ABAP codes cannot
possible.The SAP SmartForms replace the SAPscript forms. SAP SmartForms offer
the following advantages:

Creating and maintaining forms requiring half the time


Adapting forms without any programming knowledge due to entirely
graphical user interface
Web Publishing using the generated XML output

Potrebbero piacerti anche