cancel
Showing results for 
Search instead for 
Did you mean: 

Sap script printing

Former Member
0 Kudos

Hi All

I am executing a a program which genereates sapscript. I want to run this program as back ground job. To do this i have to supress the print screen. What parameters i need to pass to supress the screen & create a new spool request.

Thanks in advance

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi

Declare the following :

wa_ctrlop TYPE ssfctrlop, " Smart Forms: Control structure

wa_outopt TYPE ssfcompop, " SAP Smart Forms: Smart Composer (transfer)

<b>Set the following options to supress the print screen:</b>

wa_ctrlop-no_dialog = 'X'.

wa_outopt-tdnoprev = 'X'.

<b>Generate New Spool id:</b>

wa_outopt-tdnewid = 'X'.

Former Member
0 Kudos

Geeta Its not a smartform its sap script

Former Member
0 Kudos

Hi

You can use a Logic in your report by using the table ITCPO for SAPscript output interface

TDPAGESLCT--> Pages selected for printing 60

TDCOPIES--> Number of copies 3

TDDEST--> Output destination 4

TDPRINTER--> Device type 8

TDPREVIEW--> Print preview 1

TDNOPREV--> Suppress print preview 1

Table ITCPO - SAPscript output interface

Spool Control

Print Immediately - itcpo-tdimmed = 'X'.

Delete after print - itcpo-tddelete = 'X'.

New spool request - itcpo-tdnewid = 'X'.

Output device - itcpo-tddest = 'SAP1'.

Calling layout script from ABAP/4

call function 'OPEN_FORM'

exporting

form = space

language = 'E'

device = 'PRINTER'

options = itcpo

dialog = 'X'

exceptions form = 5.

call function 'START_FORM'

exporting

form = 'ZSAP_FORM'

language = 'E'

startpage = 'FIRST'.

call function 'WRITE_FORM'

exporting

window = 'MAIN'

type = 'BODY'

element = 'HEADER_TEXT'.

call function 'END_FORM'.

call function 'CLOSE_FORM'

Check this link

Regards

Pavan