Any number of macro steps can be stored per macro. A macro step determines which system is used to create a form and whether anything should be created at all.
The following is a rough outline of what happens in a macro step:
Execute start script - Query or define variables - Generate form - Execute macro output - Execute End script
It is also possible to integrate loops. The visible input fields depend on the generation function.
PATH: Administration > System Initialization > Report Setup > "Open" a report > "Macro Step" tab > "Open" a macro step.
Window report_makrostep_edit_page1.psr
The following fields are generally available:
Name
|
Description
|
Creation with
|
The system to be used to create the report can be specified here.
Note: Beas use the SAP Crystal engine for displaying reports.
But SAP Crystal report is not a product of Beas.
|
Name
|
Name of the macro step
|
Run at
|
Here you configure the condition under which the macro step should be run, e.g. only run if it was started via View.
A script named "Run only if" can be stored for this purpose. If this script returns "return failure", this step is not executed.
The filter function must not be confused with the creation function. This allows you e.g. to print by clicking on “Email”, or create an email on printing.
|
Start instructions
|
Beas script which is executed before the report is created.
|
End instruction
|
Beas script which is executed after the report is created.
|
Loop SQL-Query
|
Loop function (see example below)
|
Set print ID
|
(Marketing window only): Print ID is set.
|
Creation with
A report can be created in the following ways
Name
|
Description
|
Crystal
|
The report was created with Crystal. The form is available as an RPT file.
|
Beas form
|
The report was created with Infomaker or Powerbuilder and saved as a beas form (PSR file).
Important:
If the macro variables should be passed in the call of the base form, they must begin with "var_".
|
SQL Query
|
An SQL instruction was stored.
|
Current window
|
The current window is used.
|
No Creation
|
No form is created – e.g. for re-use of existing files.
|
Additional inputs for Crystal
Name
|
Description
|
File Name
|
File has to be located in one of the following folders:
c:\program files (x86)\beas software\beas\program
c:\program files (x86)\beas software\beas\program\report
[project folder]\
[project folder]\report
Alternatively, you can set up the file name in macro step, by setting the variable makro_filename (beas 9.1 PL: 08)
Example:
setvar=makro_filename=my_own_report.rpt
Note:
Beas uses Crystal 11 Viewer.
Only object types can be viewed which are known to the Crystal 11 Viewer.
|
|
Deactivate Connection Check
|
A Crystal document is defined for a specific database or connection. Beas breaks the connections stored there and links the form to the current database.
If you do not want this (e.g. because a result is expected from a process), you can deactivate this setting here.
Note: This flag is only available in MSSQL.
|
Deactivate Parameter Input
|
Beas retains the Crystal parameter input and provides multilingual, user-friendly parameter input. However, if you want to work with the Crystal parameter input, the Beas function can be deactivated here.
|
External Report
|
If this option is activated, all beas influence is deactivated, e.g. translation, formula breakdown, etc.
|
Additional inputs for SQL query
Name
|
Description
|
SQL Query
|
SQL instruction from which a report is created.
|
Tab
Name
|
Description
|
Macro Step
|
Defines the macro step.
|
Variables
|
Defines the variables and parameters.
|
Macro Output
|
Defines the output steps.
|
Scripts
|
Defines scripts for Macro start, SQL query for Loop and Macro end. Click on the yellow arrow to open the beasgui script editor.
Window report_makro_edit_scripts.psr
|
Example: use loop function in macro step:
Help URL: https://help.beascloud.com/beas202109/index.html?makroschritt.htm
|