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: 

Smartform Related

AbhijeetK
Active Participant
0 Kudos
179

Hello,

Is it possible that there should be one driver program but smartform are more than one.

If yes than how do we make relation ?

Thanks

Abhijeet kankani

1 ACCEPTED SOLUTION

arindam_m
Active Contributor
0 Kudos
76

Hi,

The smartform get generated and returns FM_NAME by the FM SSF_FUNCTION_MODULE_NAME. Pattern is similar to:

CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
  EXPORTING
    FORMNAME             = '<form name>'
  IMPORTING
    FM_NAME              = fm_name
  EXCEPTIONS
    NO_FORM              = 1
    NO_FUNCTION_MODULE   = 2
    OTHERS               = 3.

IF SY-SUBRC <> 0.
   <error handling>
ENDIF.

Also details in link:

http://help.sap.com/SAPHELP_NW04s/helpdata/EN/1c/f40c5bddf311d3b574006094192fe3/content.htm

The <form name> is a value that you can decide and pass based on condition via a variable. This would give you the relevant function module name based on whatever Smartform you pass.

Cheers,

Arindam

7 REPLIES 7

former_member188827
Active Contributor
0 Kudos
76

Yes, you can put condition in your driver program and call the relevant form on the basis of your condition. Can you share what exactly your requirement is?

Regards

former_member259807
Active Participant
0 Kudos
76

Yes. By basically change the driver program and add coding for calling the second (and third and so on) smartform. But is that what you mean?

Regards,

Bob

Former Member
0 Kudos
76

Hi Abhijeet,

You can have Single driver with multiple smart forms having different output types. Get them properly configured in NACE( Same driver name but diff SmartForm/PDF form name) and use them.

A question is what is the need to have two diff. forms, is the requirement to display form in diff. languages or the data/layout is changing.

BR.

Message was edited by: Ankit Maskara

arindam_m
Active Contributor
0 Kudos
77

Hi,

The smartform get generated and returns FM_NAME by the FM SSF_FUNCTION_MODULE_NAME. Pattern is similar to:

CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
  EXPORTING
    FORMNAME             = '<form name>'
  IMPORTING
    FM_NAME              = fm_name
  EXCEPTIONS
    NO_FORM              = 1
    NO_FUNCTION_MODULE   = 2
    OTHERS               = 3.

IF SY-SUBRC <> 0.
   <error handling>
ENDIF.

Also details in link:

http://help.sap.com/SAPHELP_NW04s/helpdata/EN/1c/f40c5bddf311d3b574006094192fe3/content.htm

The <form name> is a value that you can decide and pass based on condition via a variable. This would give you the relevant function module name based on whatever Smartform you pass.

Cheers,

Arindam

AbhijeetK
Active Participant
0 Kudos
76

Thanks all for all ur valuable suggestions, I myself got the solution.

0 Kudos
76

Hi Abhijeet,

                        yaa..u can use condition in your driver program and call the relevant form on the basis of your condition.

and even u can try this t-code- NACE for different conditions.

Cheers,

Dpk

0 Kudos
76

Thanks