Application Development 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: 

Table control

Former Member
0 Kudos

Hello,

i hav a table control with 15 fields..i am creating 2 transactions for the same table control..

i want that when i call the first transaction only the first 10 fields shud get displayed in my table control and when i call the second transaction the last 5 fields shud get displayed..

plz guide

1 ACCEPTED SOLUTION

anversha_s
Active Contributor
0 Kudos

HI,

use the tcoe SY-TCODE.

using this u will get current t code of ur program.

put this in the if condition in ur PBO.

Rgds

anver

5 REPLIES 5

anversha_s
Active Contributor
0 Kudos

HI,

use the tcoe SY-TCODE.

using this u will get current t code of ur program.

put this in the if condition in ur PBO.

Rgds

anver

Former Member
0 Kudos

before fetching data into table control internal table. first u check the transaction code. i.e. using sy-tcode.

ex, if sy-tcode = 'T1'.

pass only the 10 values to internal table .

elseif sy-tcode = 'T2'.

endif.

dani_mn
Active Contributor
0 Kudos

HI,

by checking the sy-tcode you can put your logic in PBO.

by using the invisible property you can hide the columns in table control you can check column by index.

check the example code.

DATA: waa LIKE LINE OF TAB_CONTROL-cols.
CLEAR waa.

      LOOP AT TAB_CONTROL-cols INTO waa.

        IF waa-index = 1 OR 
            waa-index = 2.

          waa-invisible = 'X'.
          MODIFY TAB_CONTROL-cols FROM waa.

        ENDIF.

      ENDLOOP.

Regards,

former_member735409
Participant
0 Kudos

Hi,

U can use ST-TCODE in your PBO events.

using this system command you can control the fields..

Former Member
0 Kudos

THANKS