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: 

Modify Line

Former Member
0 Kudos

Hi Friends,

I have check boxes in Basic list.

IF i select menu <SELALL>, then all check boxes should be checked.

I tried with MODIY LINE , but facing problem.

Please help me how to do this.

Thaks in Advance,

Murali Krishna K

6 REPLIES 6

Former Member
0 Kudos

when all checkboxes have been selected.....

loop at itab where checkbox = 'X'.

write code here....

modify itab where index = sy-tabix.

endloop.

Former Member
0 Kudos

Hi Murali!

You can study the form "mark_all" in the include LSETBF01.

Or you can use this code:

do.

read line sy-index field value input_entry.

if sy-subrc ne 0.

exit.

endif.

read line sy-index field value sy-lisel into my_lisel.

if my_lisel1(1) = ' ' and my_lisel1(1) ne '-'

and sy-index ne 1

and sy-index ne 3.

my_lisel+1(1) = 'X'.

modify line sy-index field value sy-lisel from my_lisel.

endif.

enddo.

Former Member
0 Kudos

Hello,

Once the select all is selected the list should be displayed with all the check box selected.

Handle checking all the check boxs by checking that particular field.

Try in this way and let me know if u still face the problem.

Regards

0 Kudos

Hi Friends,

Thanks for Your response.

But my problem is different.

CASE SY-UCOMM.

WHEN 'SELALL'.

LOOP AT I_HEADER.

I_HEADER-CHECK = C_XFLAG.

MODIFY I_HEADER.

MODIFY LINE V_LINEINDEX FIELD VALUE I_HEADER-CHECK.

V_LINEINDEX = V_LINEINDEX + 6.

ENDLOOP.

i am using this code. But in o/p current line overlapping with report header values.

what to do now.

Thanks,

Murali Krishna K

Former Member
0 Kudos

lines = sy-linno - 1.

when 'SELECTALL'.

lines = lines + 1.

do lines times.

READ LINE sy-index FIELD VALUE check.

IF check = space.

check = 'X'.

MODIFY LINE sy-index

FIELD VALUE check.

ENDIF.

enddo.

Hope this will help u. If u have still problem then write me, i will send you the whole coding.

0 Kudos

Hi Friends,

Now i can update check box but i am facing problem in otherfields of the same row,

How to update total line.

If i use MODIFY LINE V_LINEINDEX LINE VALUE FROM I_HEADER.

i am getting error ""I_HEADER" cannot be converted to a character-type field."

Thanks,

Murali Krishna K