cancel
Showing results for 
Search instead for 
Did you mean: 

highlight at table control

Former Member
0 Kudos

hai,

i want to highilight few records(either by color change) while displaying records in table control.

is it possible?

ambichan.

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

The screen cursor will by default go to the first field that is ready for input. So the first four fields of your table control are probably set for display only. This behavior can be changed by using the command in your PBO module.

SET CURSOR FIELD <f> LINE <lin> [OFFSET <off>].

<f> - the field for cursor placement

<l> - line in the table control

<off> - placement within the field

Jerrod Baldauf

Former Member
0 Kudos

To hightlight a row in a table control. Use the same logic for allowing a user to select rows.

1. On the attributes of the table control, there is an option for "w/selcolumn". Select this option and enter a variable name. The variable will be used to tell the table control which row is selected(highlighted). Define this variable as character lenght 1.

2. Within your PBO logic for the table control. Set the value of the variable to 'X' for the row(s) that you want to highlight.

loop with control buffer_control.

buf_sel = 'X'. "Highlight the row

endloop.

3. Within your PAI logic for the table control. You can determine which rows are highlight or selected by the user by checking the value of the variable.

Former Member
0 Kudos

HEY

hai thanks for your reply.

let me try out. Moreover

I have one problem in dynpro screen attached with table control. Whenever i click the button in initial screen and goes to next screen which has tablecontrol, it displays tablecontrol from 5coloumn onwards. each time i need to arrow left to see the first column its horrible.

i dont know where the bug is ..could u pls suggest me.

why.

ambichan

former_member182371
Active Contributor
0 Kudos

it seems as if you had several columns of the tablecontrol '<i>fixed</i>' and thus the cursor goes to the first column '<i>not fixed</i>'.

Try to use statement:

<b>SET CURSOR FIELD</b> 'WA_PEDIDO-QUANT' <b>LINE</b> 1.

where wa_pedido-quant would be one of the columns set as fixed.

Hope it helps.

Best regards

Former Member
0 Kudos

Not possible in table control, possible in ALV.

Regards,

Subramanian V.

Former Member
0 Kudos

thanks for your reply.

i have group of records have to be listed in tablecontrol.

for each group of records i will have one INFO header record.

I want to differentiate that record from other records

while displaying.can we atleast make intensified? or do we have any other alternate option for this.

ambichan.

Former Member
0 Kudos

I doubt, you can do those things in table control.

If your requirement is just to display, you can use

REUSE_ALV_HIERSEQ*

Function module.

This is just for display purpose and especially for header/item details display.

Regards,

Subramanian V.

Former Member
0 Kudos

How about an icon variable at the beginning of the row in the table control to highlight the INFO header record?

How about a character field at the beginning of the row that is set to '******' for the INFO header record and set to spaces for the non headers?

ALV has strong support for coloring rows. If you are using the table control for output only, then I recommend ALV.

Let us know how it goes.

Former Member
0 Kudos

hey

i used below logic to intensify the row.

LOOP AT SCREEN.

IF screen-name = 'ZMW0001-TRKORRNUM' .

IF G_ZTABIMP_SORT_WA-HOLD = 'W'.

screen-intensified = 1.

MODIFY SCREEN.

ELSE.

screen-intensified = 0.

MODIFY SCREEN.

ENDIF.

endif.

endif.

endlooop.

You have told adding icon variable is possible in header

record. pls let me kno whow to use it with this code.

we not interested in ALV as of now.

Doubt : Apart from this issue. I have one problem in dynpro screen attached with table control.

Whenever i click the button in dynpro and goes to next screen which has tablecontrol, it displays tablecontrol

from 5coloumn onwards. each time i need to arrow left

to see the first column its horrible.

i dont know where the bug is ..could u pls suggest me.

ambichan.