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

table control

Former Member
0 Likes
658

hello friends,

i am told that i will be implementing table control in module pool, next week.

can any one plz tell me which commands to use and what their purpose is.

thanks and reagrds.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
638

Hi

syntax:

CONTROLS

Regards

Anji

6 REPLIES 6
Read only

Former Member
0 Likes
639

Hi

syntax:

CONTROLS

Regards

Anji

Read only

Former Member
0 Likes
638

hi,

<b>follow these steps for implemeting table control in module pool program.</b>

1) <b>Declaration of table control in the module pool program</b>

<b>syntax</b>

<b>CONTROLS <name> TYPE TABLEVIEW USING SCREEN <screen number>.</b>

here name----> table control name( give you as per your needs)

screen number---->provide in which screen you design table control

2) <b>Desiging table control on screen.</b>

to design table control on the screen, you need SE51(screen painter) here click on TABLE in control bar and place it on the screen . you can adjust the length and width of the table control.

name the table control (here you need to use the same name which you have used for declaration of table control in module pool program.

3) <b>passing data to table control.</b>

you need to code a LOOP statement in both PBO and PAI event of the screen.

with LOOP statement ypu can transfer data from program to table control and table control to program.

<b>syntax</b>

PBO.

LOOP AT <internal table> WITH CONTROL CURSOR < scroll variable>.
module assign.
ENDLOOP.

PAI.
LOOP AT <internal table>.
ENDLOOP.

<b>in module poop program.</b>

module assign.
**sample code.
kna1-kunnr = itab-kunnr.
kna1-name1 = itab-name1.
kna1-ort01 = itab-ort01.
endmodule.

the tableview has few importent fields like..

LINE----> number of displayable rows in a table.

TOP_LINE----> the row of table where the screen dispalys start.

CUREENT_LINE----> the row currently being placed inside LOOP.

regards,

Ashokreddy.

Read only

Former Member
0 Likes
638

thank you friends, for the replies,

can any one plz tell me

1)how to track changes,

2) disable few input fields

thanks again.

Read only

0 Likes
638

hi,

2)IN ONE OF THE pbo MODULES WRITE BELOW CODE.

DATA:cols TYPE cxtab_column.

LOOP AT TABC_200-cols INTO cols.

IF cols-SCREEN-FIELDNAME = 'UR FIELD'.

cols-SCREEN-INVISIBLE = '1'.

MODIFY TABC_200-cols FROM cols.

ENDIF.

ENDLOOP.

RGDS,

BHARAT.

Read only

0 Likes
638

Hai,

To modify the screen you have to use the table control structure.

You will get a structure with the name which you created the table control.

this structure is called deep structure. Deep structure means a structure with one of the field is an internal table or string or xstring. In this case this structure contains one internal table as one of the field. Here in this structre you have fields to modify the table control and the internal table contains the information about the columns. By using this you can modify the columns of the internal table.

you will get the structure with the name of the table control which you are declaring in the top include.

For better reference go through the seimens material. Its good for beginers.

Read only

0 Likes
638

use demo program to get better idea

DEMO_DYNPRO_TABCONT_LOOP