2007 May 14 7:23 AM
hi .
i have an internal table with a checkbox column.
using interactive report plz tell me how to display only those fields which i have checked
2007 May 14 7:44 AM
hi .
i have an internal table with a checkbox column.
using interactive report plz tell me how to display only those fields which i have checked
2007 May 14 7:27 AM
Hi,
Loop at <itab>.
if itab-checkbox = 'X'.
write : itab-v1.
Endif.
Endloop.
Regards,
Padmam.
2007 May 14 7:30 AM
hi,
if itab_final- checkbox = 'X'.
sttements.
endif.
reward with points if helpful.
2007 May 14 7:32 AM
i cannot change the chk box value in itab using this loop as the check box is selected from the screen using mouse which does not change values in itab
2007 May 14 7:46 AM
Hi,
You have read the data from the list o/p.
data: begin of itab1 occurs 0,
wline(600),
end of itab1.
data: wa like itab. "The final internal table is itab.
if any_click_event .
refresh itab.
get cursor line line_no value wa.
if sy-subrc eq 0.
do.
read line line_no line value into wa.
if sy-subrc = 0.
itab1-wline = wa-(firstfield) "eg : wa-vbeln.
append itab1.
hide itab1.
clear itab1.
clear wa.
endif.
else.
exit.
endif.
line_no = line_no + 1.
enddo.
endif.
Reward points if it helps.
Regards,
Kumar.
2007 May 14 8:14 AM
Hi,
in my previous post in the code after those data declarations declare the event,
At Line-selection, and then use the code which I have sent you, accordingly.
Regards,
Kumar.
2007 May 14 7:44 AM
2007 May 14 7:46 AM
you have to use like this...
put a push button in application toolbar.
at user-command.
case sy-ucomm.
when 'PUSH'.
describe table itab lines lin<which will hold the line val>
do lin times.
read line sy-index line value into wa.<wa like your itab you are displaying>
if wa-chk = 'X'.
append wa to itab2<which you want to show in next list>.
endif.
enddo.
loop at itab2.
<your write statement for next list..
endloop.
endcase.
regards
shiba dutta
2007 May 14 8:04 AM
Hi,
Try this...
REPORT ztest_prog NO STANDARD PAGE HEADING.
DATA: BEGIN OF wa,
check,
name(30),
END OF wa,
itab LIKE STANDARD TABLE OF wa,
wa_itab LIKE wa.
DATA: lin TYPE i.
START-OF-SELECTION.
wa-name = 'ABAP'.
APPEND wa TO itab.
wa-name = 'BSP'.
APPEND wa TO itab.
wa-name = 'DYNPRO'.
APPEND wa TO itab.
LOOP AT itab INTO wa.
WRITE: / wa-check AS CHECKBOX, wa-name.
HIDE wa.
ENDLOOP.
CLEAR wa.
DESCRIBE TABLE itab LINES lin.
AT LINE-SELECTION.
DO lin TIMES.
READ LINE sy-index LINE VALUE INTO wa.
IF sy-subrc = 0 AND wa-check = 'X'.
WRITE: / wa-name.
ENDIF.
CLEAR wa.
ENDDO.
Thanks & Regards
Santhosh
2007 May 14 7:50 AM
Hi Karan,
loop at itab1 where chk_box = 'X'.
append itab1 to itab2.
endloop.
at line-selection.
case sy-lsind.
when 1.
loop at itab2.
write:/10 itab-field1,itab2-field2.........
endloop.
Reward points if helpful.
Regards,
Hemant