Application Development and Automation 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: 
Read only

doubt in smartform driver program

Former Member
0 Likes
815

Hi all,

in Smartform driver program we have use,

data: fm_name TYPE rs38l_fnam. and below two function modules.

CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'

CALL FUNCTION fm_name .

but in the actual Global settings under global definitions node, we have to use TYPES stmt for declaring TYPES and in Under global Data we declare Internal tables and work area and in under Initialization we write all the select statements etc.

My question is :

in the driver proram also we have to use all types stmts, Itab decalrations and Select stmts.and we comment in the same in the smartform ?

if it is yes, how do we pass the same to smartform?

Thanks in advance

KR

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
772

hi

If you are defining and populating your internal table in the form itself then,

you dont want to declare all type statments again in the

driver program.But it is always a good practice to populate the internal table in the driver program

and pass the data to the form.

i have written a WIKI on this .Have a look at that.

See the question

2 . How to get the function module name automatically in the driver program?WITH EXAMPLE. [https://wiki.sdn.sap.com/wiki/display/ABAP/SMARTFORMguide]

This will solve your problem.

Regards

Hareesh.

Edited by: Hareesh Menon on Feb 12, 2009 9:54 AM

6 REPLIES 6
Read only

viquar_iqbal
Active Contributor
0 Likes
772

Hi

You dont need to declare them again in the driver program once declared in smartforms

Thanks

Viquar Iqbal

Read only

rejish_balakrishnan
Contributor
0 Likes
772

Hi ,

Unlike scripts smart forms allows you to declare global data and global types.A separate driver program is not required.If u wish then declare in any one of itEilter in driver program or in msartforms.But not in both .

Read only

0 Likes
772

ok..

thansk for inputs.

now i wiant to declare types, itabs, and other validations in the driver program. how do i pass the final table to SF ?

thanks in advance

KR

Read only

Former Member
0 Likes
772

Hi KR,

You dont have to declare the same again in the print program.You can do all that using smartforms it self.

Much Regards,

Amuktha.

Read only

Former Member
0 Likes
773

hi

If you are defining and populating your internal table in the form itself then,

you dont want to declare all type statments again in the

driver program.But it is always a good practice to populate the internal table in the driver program

and pass the data to the form.

i have written a WIKI on this .Have a look at that.

See the question

2 . How to get the function module name automatically in the driver program?WITH EXAMPLE. [https://wiki.sdn.sap.com/wiki/display/ABAP/SMARTFORMguide]

This will solve your problem.

Regards

Hareesh.

Edited by: Hareesh Menon on Feb 12, 2009 9:54 AM

Read only

Former Member
0 Likes
772

Hi KR,

There is a a function module that will be generated with your smartform.

You have to call it in your program.

Now in your program you also write some internal table logic.

Example say your internal table is t_flight with fs_flight-carrid and fs_flight-connid as its fields.

So in your form you can just call it using '&' like &fs_flight-carrid&.

Much Regards,

Amuktha.