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

Disable ALV checkboxes

Former Member
0 Likes
902

I have ALV with field wich is shown as checkboxes.

How to disable some of checkboxes?

I have ALV with field wich is shown as checkboxes.

How to disable some of checkboxes?

7 REPLIES 7
Read only

Former Member
0 Likes
874

Hi,

did you serach in SDN, did you try FIELDCAT?

Regards, Dieter

Read only

Former Member
0 Likes
874

I want to disable not ALL checkboxes of column, i want to disable some of checkboxes.

Read only

Former Member
0 Likes
874

there will be a field called selkz

in field catalog

WHEN c_checkbox.

ls_fcat-col_pos = 0.

ls_fcat-row_pos = 1.

ls_fcat-outputlen = 2.

ls_fcat-checkbox = 'X'.

ls_fcat-edit = ''X.

ls_fcat-tabname = c_out_tab.

dont put the statement ls_fcat-edit = 'X'.

P.S. c_checkbox is of type selkz

Regards

PalaK

Read only

0 Likes
874

Yes.

But this code will cause disabling of all checkboxes of column.

Read only

Former Member
Read only

0 Likes
874

FORM adjust_editables USING pt_list LIKE gt_list[] .

DATA ls_listrow LIKE LINE OF pt_list .

DATA ls_stylerow TYPE lvc_s_styl .

DATA lt_styletab TYPE lvc_t_styl .

LOOP AT pt_list INTO ls_listrow .

IF ls_listrow-carrid = 'XY' .

ls_stylerow-fieldname = 'SEATSMAX' .

ls_stylerow-style = cl_gui_alv_grid=>mc_style_disabled .

APPEND ls_stylerow TO lt_styletab .

ENDIF .

IF ls_listrow-connid = '02' .

ls_stylerow-fieldname = 'PLANETYPE' .

ls_stylerow-style = cl_gui_alv_grid=>mc_style_enabled .

APPEND ls_stylerow TO lt_styletab .

ENDIF .

INSERT LINES OF lt_styletab INTO ls_listrow-cellstyles .

MODIFY pt_list FROM ls_listrow .

ENDLOOP .

ENDFORM .

Read only

0 Likes
874

Hi,

Take a look at the example programs in the pacakage SLIS.Especially program BCALV_EDIT_02.

regards,

Advait