cancel
Showing results for 
Search instead for 
Did you mean: 

How to Define Internal Table in Smartform

Former Member
0 Kudos

Hello,

I have some problem on define Internal Table in Smartform

I define a Temp_IT_Gen Type LBBIL_IT_GEN in Global Definiations

but i find that it is not available for me to append data into it,

the error message is Temp_IT_Gen is not a Internal Table - the Occurs n Specification is missing

so how can i solve it?

i want to use the internal table in the hold program.

Thanks a lot in advance.

Accepted Solutions (0)

Answers (6)

Answers (6)

Madhurivs23
Participant
0 Kudos

Define a table type in the data dictionary and then declare it in the global definitions.

OR you can make use of table type LB_T_BIL_IT_GEN for which the line type LBBIL_IT_GEN has been used.

Edited by: madhuri sonawane on Jun 10, 2009 4:38 PM

Former Member
0 Kudos

Hi,

In global definitions insted of 'TYPE' use 'Type table of'.

Former Member
0 Kudos

Hi,

You can define an internal table in smartform. In Global definitions --> Under TYPE tab

Define the structure and table type of internal table.

For ex:

TYPES: BEGIN OF TY_REDEC,

INGPR TYPE INGRP,

EQUNR TYPE EQUNR,

AUFNR TYPE AUFNR,

QMNUM TYPE QMNUM,

END OF TY_REDEC.

TYPES: TT_REDEC TYPE STANDARD TABLE OF TY_REDEC.

Than in Global data define the Internal table and Its work Area as below:

GT_REDEC TYPE TT_REDEC

GS_REDEC TYPE TY_REDEC.

Hope this may be useful..

Regards,

Prashant

Former Member
0 Kudos

Hai Jamison,

Just need to make a small change and this error will stop poping up.

In GLobal definition under column-> Type assignment -> just enter "TYPE TABLE OF" instead

of "TYPE".

This will surely solve your problem. Revert back in cae the problem persisits.

Cheers,

Suvendu

Former Member
0 Kudos

Hi,

First U define the Table type in 'TYPES' tab of Global Definitions and then assing that table type to Internal table in 'Global Data' tab.

Eg:

define the Table Type like below in TYPES tab.

TYPES:BEGIN OF ty_TEMP.

INCLUDE STRUCTURE XXXXXXX.

TYPES:END OF ty_TEMP.

TYPES: g_t_temp TYPE STANDARD TABLE OF ty_TEMP .

Now, define the Internal table in Global Data tab like below:

Variable Name Type assignment Associated Type

G_T_ITEM_1 TYPE G_T_TEMP

NOTE: whatever U define in Global Definitions can be used only in SMARTFORM, if u want to use it in Program U must define in Form Interface.

Hope it helps!!

Rgds,

Pavan

Former Member
0 Kudos

Hi

Use type table of instead of type in Global definitions

Temp_IT_Gen Type Table Of LBBIL_IT_GEN " Changed type to type table of 

(or)

In form definitions you have a tables tab you can even define it here which will reflect the function module. that is when you use the smart form in driver program you will be able to see the Tables parameter also so you can pass the data through the your driver program

now you can use temp_it_gen as internal table and you can even append data to it.

Thanks&Regards

Sarves