文档详情

ABAP--如何在选择屏幕上输出ALV GRID报表(国外英文资料).doc

发布:2017-06-07约1.19万字共16页下载文档
文本预览下载声明
ABAP--如何在选择屏幕上输出ALV GRID报表(国外英文资料) Some clients want some functional report to see the input parameters on the screen at the same time when the report is output I want to be able to query the selection criteria over and over again. The way to do this is to output the report content on the screen. In general, you will find the corresponding routines directly from the SAP system and then modify them. But SAP system The routines of the series are object-oriented development, which is not quite the custom of our group of old birds. I took a closer look at this routine, Change it to our usual programming model. The code sees the attachment, and the details are as follows: The selection screen is also a screen, unlike the one created in general: it doesnt have a PBO, a PAI event, or a report program The INITIALIZATION is the PBO event that selects the screen, and other events are the PAI events that select the screen. Specific event and program functions The code is as follows: INITIALIZATION. PERFORM sub_init_cond. initialize the selected screen field PERFORM sub_create_fieldcat. PERFORM sub_init_layout. PERFORM sub_create_object. create the object on the screen START - OF - SELECTION. PERFORM sub_process_cond. handle the selection criteria PERFORM sub_query_t006a. query the relevant data The END - OF - SELECTION. PERFORM sub_refresh_table. refresh the data in the inner table We created the ALV GRID output needed for the INITIALIZATION event. If the output inner table GT_RESULT [] is Empty, skip this code; If the output inner table GT_RESULT [] is not empty, you create the object that ALV GRID needs, The contents are then printed on the selected BLOCK on the screen. System MEMORY ID sy-cprog is a global storage area used to store the table data in the result. If it doesnt feel convenient A new inner table can be defined to hold the data for the resulting inner table. The contents of the IMPORT MEMORY ID are assigned to the result In the inner table, the data in the resul
显示全部
相似文档