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

smart forms-HOW TO DECLARE AN INTERNAL TABLE CONTAINNING FIELDS FROM DIFFER

Former Member
0 Likes
586

Hi Experts,

HOW TO DECLARE AN INTERNAL TABLE CONTAINNING FIELDS FROM DIFFERENT TABLES.

Problem:

iam working on smartforms. In driver program iam getting data from different tables and at last in final internal table i have fields from different tables.

i need to pass this internal table to smartforms function module.now the problem is how i have to define this table in smartforms.

what i tried.

declared one structure with this fields in globle declaration under TYPES tab.

and under INIATIALIZATION tab i have created internal table refering to structure declared under TYPES and same i have declared in export paramters of interface structure. but when i use this internal table in LOOP it is throughing error that it is not defined under tables .

Please Advice.

Thanks In Advance.

Thanks,

Praveen.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
550

Hi,

For smartforms..It is better to create a structure in the DDIC with the fields from the final internal table..And then use it in the Tables parameter...

I am not sure how to use a local structure..

Thanks,

Naren

Hi Experts,

HOW TO DECLARE AN INTERNAL TABLE CONTAINNING FIELDS FROM DIFFERENT TABLES.

Problem:

iam working on smartforms. In driver program iam getting data from different tables and at last in final internal table i have fields from different tables.

i need to pass this internal table to smartforms function module.now the problem is how i have to define this table in smartforms.

what i tried.

declared one structure with this fields in globle declaration under TYPES tab.

and under INIATIALIZATION tab i have created internal table refering to structure declared under TYPES and same i have declared in export paramters of interface structure. but when i use this internal table in LOOP it is throughing error that it is not defined under tables .

Please Advice.

Thanks In Advance.

Thanks,

Praveen.

3 REPLIES 3
Read only

Former Member
0 Likes
551

Hi,

For smartforms..It is better to create a structure in the DDIC with the fields from the final internal table..And then use it in the Tables parameter...

I am not sure how to use a local structure..

Thanks,

Naren

Read only

amit_khare
Active Contributor
0 Likes
550

Hi,

You are doing almost right just instead of Initialization event declare the table in Global Data in Global Definitions tab.

Regards,

Amit

Read only

Former Member
0 Likes
550

Hi,

Declare the structure in your Data dictionary (SE11).

and in 'Form interface', define a variable under the Tables tab referringto this structure.

Thats it.

Now when you generate the smartforms, the func module will have the TABLES parameter where you can pass your internal table.

Regards

Subramanian