09-18-2008 6:37 AM
when i delete a row from table conrol the serial numbers attached to it ishould also be accordingly changed..but it is not happening..
ex : i have 3 rows in my table control and i deleted 2 row..then the serial numbers should be 1 & 2..but i'm getting the ser num as 1 & 3. How to decrement the serialnums.
09-18-2008 6:41 AM
Hi,
try like this...
delete itab where mark eq 'X'.
tc-lines = tc-lines - 1.
num = 1.
loop at itab into wa.
wa-slno = num.
modify itab from wa transporting slno.
num = num + 1.
endloop.
clear num.
Regards,
Sathish Reddy.
09-18-2008 6:40 AM
When you delete a record, loop the intenal table and modify the serial number
Regards
MD
09-18-2008 6:41 AM
Hi,
try like this...
delete itab where mark eq 'X'.
tc-lines = tc-lines - 1.
num = 1.
loop at itab into wa.
wa-slno = num.
modify itab from wa transporting slno.
num = num + 1.
endloop.
clear num.
Regards,
Sathish Reddy.
09-18-2008 6:42 AM