cancel
Showing results for 
Search instead for 
Did you mean: 

Regrding smartform

Former Member
0 Kudos

Hi ,

Does driver program is require for smartform ? If how do u link smartform with driver program?

Thanks in advance

Ramesh

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Driver program is required for a smartform.

I guess it can also be managed in the smartform itself by using the program lines, but Im not sure about this.

In the driver program, we call the FM SSF_FUNCTION_MODULE_NAME, by passing the form name to this FM we get the FM which will be generated by our Smartform.

In the nxt step call the FM that is generated by the smartform to get the desired output.

To put it simple: say zform is your sf.

CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'

EXPORTING

formname = 'ZFORM'

IMPORTING

fm_name = fnam.

IF sy-subrc <> 0.

MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno

WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.

ENDIF.

CALL FUNCTION fnam

EXPORTING

gv_name = gv_name

TABLES

gt_itab = gt_itab.

Hope it helps.

Regards,

Narendra.

Reward points if helpful!!

FYI some links to Smartforms:

SmartForm Tutorial

http://www.sap-basis-abap.com/sapsf001.htm

here is a link which will teach you step by step

http://smoschid.tripod.com/How_to_do_things_in_SAP/How_To_Build_SMARTFORMS/How_To_Build_SMARTFORMS.h...

Step by Step creation of Smartforms

http://www.sap-basis-abap.com/sapsf001.htm

http://www.sap-img.com/smartforms/smart-006.htm

http://www.sap-img.com/smartforms/smartform-tutorial.htm

http://www.sapbrain.com/TUTORIALS/TECHNICAL/SMARTFORMS_tutorial.html

How to trace smartform

http://help.sap.com/saphelp_47x200/helpdata/en/49/c3d8a4a05b11d5b6ef006094192fe3/frameset.htm

http://www.sap-img.com/smartforms/smartforms-faq-part-two.htm

Answers (2)

Answers (2)

Former Member
0 Kudos

hi,

yes, u require a driver program for executing a smartform.

call the FM

call function 'SSF_FUNCTION_MODULE_NAME'

exporting

formname = 'UR SMARTFORM NAME'

  • VARIANT = ' '

  • DIRECT_CALL = ' '

importing

fm_name = form_name

exceptions

no_form = 1

no_function_module = 2

others = 3

.

if sy-subrc <> 0.

message id sy-msgid type sy-msgty number sy-msgno

with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.

endif.

In the form_name u will get the FM name which the smartform generates.

call function form_name.

exporting

emporting

tables.

u can send ur values in the export paramaters to the smartform

Former Member
0 Kudos

Hi,

With out driver program how can you pass the internal table data to smartform FM.

Link is

CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'

EXPORTING

formname = 'Your Smart form name'

IMPORTING

fm_name = ws_form_fname.(This dunamic FM which will

created by program)

**Calling the Dynamic Function module So that smartform will get ***invoked

CALL FUNCTION ws_form_fname

EXPORTING

control_parameters = device

TABLES

i_final_ap = i_final_ap.