@@ -23,13 +23,12 @@ METHOD z2ui5_if_app~main.
2323 upload = client->_event( 'UPLOAD' )
2424 )->stringify( ) ).
2525
26- CASE client->get( )-event.
27- WHEN 'UPLOAD'.
26+ IF client->get( )-event = 'UPLOAD'.
2827
2928 data(lr_itab) = lcl_help=>itab_get_by_xlsx( mv_value ).
3029 "further process with itab...
3130 client->message_box_display( `xlsx uploaded` ).
32- ENDCASE .
31+ ENDIF .
3332
3433ENDMETHOD.
3534```
@@ -83,13 +82,10 @@ Convert an internal table to an XLSX file and download it as a Base64-encoded fi
8382 )->page(
8483 )->button(
8584 text = 'Open Download Popup'
86- press = client->_event( 'BUTTON_DOWNLOAD ' )
85+ press = client->_event( 'DOWNLOAD ' )
8786 )->stringify( ) ).
8887
89-
90- CASE client->get( )-event.
91-
92- WHEN 'BUTTON_DOWNLOAD'.
88+ IF client->get( )-event = `DOWNLOAD`.
9389
9490 TYPES:
9591 BEGIN OF ty_row,
@@ -102,17 +98,13 @@ Convert an internal table to an XLSX file and download it as a Base64-encoded fi
10298 DATA(lt_tab) = VALUE ty_tab(
10399 ( count = '1' value = `red` descr = `this is a description` )
104100 ( count = '2' value = `red` descr = `this is a description` )
105- ( count = '3' value = `red` descr = `this is a description` )
106- ( count = '4' value = `red` descr = `this is a description` )
107- ( count = '5' value = `red` descr = `this is a description` ) ).
101+ ( count = '3' value = `red` descr = `this is a description` ) ).
108102
109103 DATA(lv_file) = lcl_help=>xlsx_get_by_itab( lt_tab ).
110-
111104 client->follow_up_action( val = client->_event_client(
112105 val = client->cs_event-download_b64_file
113106 t_arg = VALUE #( ( lv_file ) ( `test.xlsx` ) ) ) ).
114-
115- ENDCASE.
107+ ENDIF.
116108
117109ENDMETHOD.
118110```
0 commit comments