cancel
Showing results for 
Search instead for 
Did you mean: 

How to make use of communication method in output type for new smartform?

Former Member
0 Kudos

Hi all,

My requirement, send the smartform to the carrier by fax/email/print based on the output condition records created.

Here are the things that I had done.

1) created a ZSMARTFORMS - smartforms

2) created a ZPRINTPROGRAM - print program

3) created a ZTCFRT - transaction code

3) created an ZFRT - output type

I am stuck here. What are the next steps ? I want when I run transaction code: ZTCFRT, this print program ZPRINTPROGRAM will call this ZSMARTFORMS smartforms and send/fax/print to the carrier.

It would be great that someone can share the steps with me.

Thanks!

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Have you written any code in your program or just Created it?

If you have only created it, then you need to call some functions in your PRINT Program and these are:

Below is just an example:


  CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
    EXPORTING
      formname           = i_formname
    IMPORTING
      fm_name            = i_fm_name
    EXCEPTIONS
      no_form            = 1
      no_function_module = 2
      OTHERS             = 3.

    CALL FUNCTION i_fm_name
      EXPORTING
        control_parameters = control_parameters
        output_options     = output_options
        user_settings      = space
        vbeln              = p_vbeln
      TABLES
        it_vbak            = it_vbak
      EXCEPTIONS
        formatting_error   = 1
        internal_error     = 2
        send_error         = 3
        user_canceled      = 4
        OTHERS             = 5.
    IF sy-subrc <> 0.
      MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
              WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    ENDIF.

After calling second function, system execution will reach to the SMARTFORM (which you have created). There in smartform you can do whatever you want.

for more details:

http://help.sap.com/saphelp_nw04/helpdata/EN/a5/de6838abce021ae10000009b38f842/content.htm

also see:

help.sap.com/printdocu/core/Print46c/en/data/.../BCSRVSCRSF.pdf

For any query, revert back.

Regards,

Vishal

Former Member
0 Kudos

Hi,

I created the print program with the codes that manage to call the smartform successfully. However, how to control that when I run this print program that call the smartform. In the print program will allow user to enter the vendor id, and when executed the smartform will be fax/sent/print to the vendor entered earlier by making use of communication method in the output type.

thanks.

Answers (0)