05-02-2008 11:17 AM
Hi All....
Iam having field in table control to display the output... Can i restrict that field as to give non zero values only?
like....
write:/ itab-field no-zero.
....in reports.....
Thank you,
Naveen.
05-02-2008 11:36 AM
Hi,
You can do that if the column will be used for output only.
PBO.
loop at internal_table with tab_ctr.
module screen_att_change.
endloop.
Module screen_att_change output.
loop at screen.
if internal_tab-value is initial.
if screen-name = 'INTERNAL_TAB-VALUE'.
screen-active = 0.
screen-invisible = '1'.
modify screen.
endif.
endif.
endloop.
endmodule.
Thanks and regards,
S. Chandra Mouli.
05-02-2008 11:20 AM
Before populating the table control, delete all entries from internal table (used as basis for your table control) where this field is empty (not initial. or NULL or what ever condition is needed for that matter).
05-02-2008 11:22 AM
Naveen,
U want to display the output in Table Control, first u get the data in Internal Table.
At the time of filling the Internal table U can restrict the fields with Only Non Zeros.
Try this Way.
Hope this Help.
Thanks,
Shiva
05-02-2008 11:25 AM
hi
can you clarify your requirement.
if you do not want to print leading Zeros than you can do like:
data: tmp(30) type c.
tmp = itab-field.
shift tmp left delete leading '0'.
write: tmp.
if you want field containing 0 should not print than u can use if condition like:
if itab-field <> 0.
write:/ itab-field.
endif.
if other than this give details
05-02-2008 11:36 AM
Hi,
You can do that if the column will be used for output only.
PBO.
loop at internal_table with tab_ctr.
module screen_att_change.
endloop.
Module screen_att_change output.
loop at screen.
if internal_tab-value is initial.
if screen-name = 'INTERNAL_TAB-VALUE'.
screen-active = 0.
screen-invisible = '1'.
modify screen.
endif.
endif.
endloop.
endmodule.
Thanks and regards,
S. Chandra Mouli.