gwa_edit-fieldname = 'UOM'. gwa_edit-style = cl_gui_alv_grid=>mc_style_disabled."设置为不可编辑 ENDIF. APPEND gwa_edit TO GS_data-celtab . MODIFY gt_Data FROM gs_Data . ENDLOOP. ... 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. 13. 14. 15. 16. 17. 18. 19. 20...
注:这里只是样式的切换,不能仅仅使用cl_gui_alv_grid=>mc_style_enabled来将单元格设置为可编辑状态,单元格真正是否可编辑是由fieldcat-edit或layout-edit来决定的,而仅设置为cl_gui_alv_grid=>mc_style_enabled是不可编辑的 gt_cellstab-style=cl_gui_alv_grid=>mc_style_disabled. APPENDgt_cellstab. gt...
ifls_celltab-style = cl_gui_alv_grid=>mc_style_enabled. "当该字段为可编辑的时候 ls_celltab-style = cl_gui_alv_grid=>mc_style_disabled. "设置该字段为不可编辑 else."当该字段为不可编辑的时候 ls_celltab-style = cl_gui_alv_grid=>mc_style_enabled."设置该字段为可编辑 endif. modifyls...
gs_style-fieldname = 'CONNID'. gs_style-style = cl_gui_alv_grid=>mc_style_disabled. INSERT gs_style INTO TABLE gt_style. ELSE. gs_style-fieldname = 'CONNID'. gs_style-style = cl_gui_alv_grid=>mc_style_enabled. INSERT gs_style INTO TABLE gt_style. ENDIF. INSERT LINES OF gt_...
data ALV_GRID1 type ref to cl_gui_alv_grid. ALV GRID继承结构: ALV_GRID介绍二(1) 四、ALV GRID相关的几个控制结构 1.字段目录 [Field catalog] 字段目录是用来控制ALV显示的网格中每个字段的属性的,比如字段的顺序,对齐方式,可编辑状态,颜色,等等. ...
gwa_edit-fieldname='列字段'.gwa_edit-style=cl_gui_alv_grid=>mc_style_enabled."设置为可编辑 ELSe.CLEAR:gwa_edit.gwa_edit-fieldname='列字段'.gwa_edit-style=cl_gui_alv_grid=>mc_style_disabled."设置为不可编辑 endif. 实例 代码语言:javascript ...
TYPE REF TO cl_gui_alv_grid 一般: CALL METHOD alv_grid ->set_table_for_first_display EXPORTING i_structure_name = 'SPFLI' CHANGING it_outtab = g_it_spfli[] . 有时候部分字段不需要输出 使用LVC_FIELDCATALOG_MERGE 函数 DATA : gb_fieldcat TYPE lvc_t_fcat . DATA ls_fldcat TYPE lvc_...
我现在就将我的理解写下来,供大家参考。1)在创建CL_GUI_ALV_GRID_BASE的对象,会调用SET_INFO_TABLE方法为MT_MODIFIED_CELLS创建一个CL_GUI_DATAPONDEMAND对象,并把MT_MODIFIED_CELLS的地址传递到CL_GUI_DATAPONDEMAND的M_DATAPTR属性;2)调用CL_GUI_DATAPONDEMAND->control_assign_prop进行注册...
GR_GRID TYPE REF TO CL_GUI_ALV_GRID, G_DOCKING TYPE REF TO CL_GUI_DOCKING_CONTAINER. *&---* *& 宏定义 *&---* DEFINE BULID_FIELDLOG. WA_STRUCTURE-FIELDNAME = &1. WA_STRUCTURE-COLTEXT = &2. 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 ...
gwa_edit-fieldname='列字段'.gwa_edit-style=cl_gui_alv_grid=>mc_style_enabled."设置为可编辑 ELSe.CLEAR:gwa_edit.gwa_edit-fieldname='列字段'.gwa_edit-style=cl_gui_alv_grid=>mc_style_disabled."设置为不可编辑 endif. 实例 ...LOOPATgt_DataINTOgs_Data.IFgs_Data-UOM='双'.CLEAR:gwa_...