report zsalv_040 .
types: begin of g_type_itab.
include type sflight.
types: exception type char1,
end of g_type_itab.
data gt_itab type table of g_type_itab.
data gs_itab type g_type_itab.
data gr_table type ref to cl_salv_table.
select * from sflight into table gt_itab
up to 25 rows.
loop at gt_itab into gs_itab.
if gs_itab-seatsocc >= 90.
gs_itab-exception = '1'.
elseif gs_itab-seatsocc >= 50.
gs_itab-exception = '2'.
else.
gs_itab-exception = '3'.
endif.
modify gt_itab from gs_itab.
endloop.
cl_salv_table=>factory(
importing
r_salv_table = gr_table
changing
t_table = gt_itab ).
data: lr_columns type ref to cl_salv_columns_table,
lr_column type ref to cl_salv_column_table.
lr_columns = gr_table->get_columns( ).
lr_columns->set_exception_column( 'EXCEPTION' ).
lr_column ?= lr_columns->get_column( 'EXCEPTION' ).
lr_column->set_short_text( 'MY EXCEPT' ).
data: lr_functional_settings type ref to cl_salv_functional_settings.
lr_functional_settings = gr_table->get_functional_settings( ).
data: lr_tooltips type ref to cl_salv_tooltips.
lr_tooltips = lr_functional_settings->get_tooltips( ).
lr_tooltips->add_tooltip(
type = cl_salv_tooltip=>c_type_exception
value = '1').
lr_tooltips->add_tooltip(
type = cl_salv_tooltip=>c_type_exception
value = '2').
lr_tooltips->add_tooltip(
type = cl_salv_tooltip=>c_type_exception
value = '3').
gr_table->display( ).
댓글 0
번호 | 제목 | 글쓴이 | 날짜 | 조회 수 |
---|---|---|---|---|
570 | REPORT Z17_011 | sapjoy | 2007.02.12 | 2287 |
569 | INCLUDE Z17_011_CLASS | sapjoy | 2007.02.12 | 2489 |
568 | REPORT Z17_012 | sapjoy | 2007.02.12 | 2304 |
567 | REPORT Z17_014. [1] | sapjoy | 2007.02.13 | 2503 |
566 | REPORT Z17_015 | sapjoy | 2007.02.13 | 2280 |
565 | REPORT Z17_016 . | sapjoy | 2007.02.13 | 2162 |
564 | REPORT Z17_017 . | sapjoy | 2007.02.14 | 2181 |
563 | REPORT Z17_019 [1] | sapjoy | 2007.02.14 | 2748 |
562 | REPORT Z17_021 . | sapjoy | 2007.02.21 | 2386 |
561 | REPORT Z17_022 | sapjoy | 2007.02.21 | 2315 |
560 | REPORT Z17_000. | sapjoy | 2007.02.22 | 2419 |
559 | REPORT Z17_020 | sapjoy | 2007.02.22 | 2172 |
558 | REPORT z17_025 | sapjoy | 2007.02.22 | 2202 |
557 | REPORT Z17_020. [2] | sapjoy | 2007.02.23 | 2185 |
556 | REPORT Z09_013 | sapjoy | 2007.02.23 | 2243 |
555 | REPORT Z17_028 | sapjoy | 2007.02.26 | 2937 |
554 | Z17_ZSFLIGHT | sapjoy | 2007.02.26 | 2413 |
553 | REPORT Z02_016 | sapjoy | 2007.02.27 | 2294 |
552 | REPORT Z18_001 | sapjoy | 2007.03.02 | 2774 |
551 | Z18_001_PBO | sapjoy | 2007.03.02 | 2585 |