Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

What I have to do in this scenario ?

Former Member
0 Kudos

Hi all,

I have this scenario.

I have a separate custom transaction (A module pool program). In that module pool program I have to keep a print button by clicking which a SAP-Script will go to spool/printer (by triggering the driver program). What is the standard procedure to do this? Should I have to create any output type for this? If yes how can I create that? And how can I trigger the driver program?

Any help will be great.

Thanks in advance.

<i></i>

2 REPLIES 2

Former Member
0 Kudos

I am not sure about SAPScript, but in SMARTFORM this is simple:

a) CALL SSF_FUNCTION_MODULE_NAME and submit the name of the form, here you can default, if you directly want it to print it out etc. The o/p is the name of the Function Module(say /BCW001/MMERT003)

b) Call the Function Module /BCW001/MMERT003

Regards,

Subramanian V.

christian_wohlfahrt
Active Contributor
0 Kudos

Hi,

in sapscript it's more depending on the print program.

I made a little report, to test my smartform, even when message aren't customized yet. This is for invoices, other forms have different values (but you should get the picture):


TABLES: nast.
DATA: return_code TYPE syst-subrc,
      us_screen  TYPE xflag.

PARAMETERS p_vbeln LIKE vbrk-vbeln.

INITIALIZATION.
  p_vbeln = '0090115726'.

START-OF-SELECTION.

  nast-objky = p_vbeln.
  nast-parnr = '0002010633'.
  nast-kappl = 'V3'.
  nast-spras = 'D'.
  nast-parvw = 'RE'.
  nast-kschl = 'ZXXX'.

  PERFORM entry(<your_report>)
              USING
                 return_code
                 us_screen.

Regards,

Christian