cancel
Showing results for 
Search instead for 
Did you mean: 

question on internal table

Former Member
0 Kudos

how to declare and use internal table in a smartform without using print program

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Vinil,

1>Go to the Global definitions.

2> In "Types" tab declare the TYPES Declarations.( internal tables using types statement.)

3>In Global data tab, declare the internal tables and work area.

4>Pass the data into the required Texts.

This should solve your query.

Reward Points if useful.

Thanks,

Tej..

Answers (5)

Answers (5)

Former Member
0 Kudos

Hi Vinil,

u can define an internal table within smartform itself...use following steps:

1) goto global definitions node

2) click on types tab. define internal in the same way which we define in abap editor...consider following code:

TYPES : BEGIN OF ty_tab,

matnr type mara-matnr,

ernam type mara-ernam,

maktx type makt-maktx,

end of ty_tab.

TYPES : tt_tab type standard table of ty_tab.

define the above in types node.

now click on global data tab.

in that define following

gt_tab type tt_tab "internal table

gs_tab type tt_tab " workarea

this way u will be defining a global internal table within samrtform....

u can also define the local internal table in program lines within SF...

hope this will help u out...

please reward points in case useful

regards,

Prashant

former_member480923
Active Contributor
0 Kudos

In the Types tab of the Samrtform declre the internal table in the following way

types: begin of types_sales,
           vbeln type vbeln,
           vkorg type vkorg,
           posnr type posnr,
           matnr type matnr,
           end of types_sales,
           types_tab_sales type standard table of types_Sales. 

in the Global Definition section declare

t_sales type types_tab_sales.

Former Member
0 Kudos

hi vinil,

select Global Definations,

go to Global Data tab,

there u can define as below,

Variable Name Type assignmentAssociated Type Default Value

L_WA_ITAB TYPE ZINV_STR_ITEM

VRKME TYPE VRKME

WAERK TYPE WAERK

TOT TYPE WAERK

L_WA_TOT TYPE FKIMG

L_WA_TOT1 TYPE ZINV_STR-TOT

L_WA_TOT2 TYPE KBETR

TOT3 TYPE IN_WORDS

WORD TYPE IN_WORDS

L_WA_NAME TYPE ZINV_STR

VBELN TYPE VBELN_VF

L_WA_TOT3 TYPE MWSBP

regards,

seshu.

Former Member
0 Kudos

hi Vinil,

You can declare them in Global definitions under types tab section.

Regards,

Santosh

former_member225631
Active Contributor
0 Kudos

Go to global definitions. In types tab declare the internal tables using types statement.In Global data tab, you have to declare the internal tables and work area.