Confusing field in Alv display

IF wa_fieldcat-fieldname      = 'XXXXX' .
      IF g_user_flag = 'X'.
        wa_fieldcat-reptext_ddic    = 'YY Price'.
        wa_fieldcat-seltext_l       = 'YY Price'.
        wa_fieldcat-seltext_m       = 'YY Price'.
        wa_fieldcat-seltext_s       = 'YY Price'.
      ENDIF.
ENDIF.

This is not a good solution,the user without authority would be confused about this field with technical field name
below are better ways to control it

  • Delete the 'XXXXX' in the fieldcat itab
WA_FIELDCAT-NO_OUT = 'X'.
WA_FIELDCAT-TECH = 'X'.
上一篇:ABAP开发基础 函数FMAVL 字段小计 金额汇总练习


下一篇:ABAP ALV显示前排序合并及布局显示