- CONVERSION_EXIT_ALPHA_INPUT 功能: 给输入的数字编号添加前置 0
- CONVERSION_EXIT_ALPHA_OUTPUT 功能: 删除输入的数字编号中的前置0
- ==============================常用的子程序=======================================
- ABAP 加 前导0 &&& 去掉 前导0 的 Function Module.
- 只要调用这两个 PERFORM. <XXXXX> 字段就会自动更改~
- PERFORM. add_zero CHANGING <XXXXX>. ” ++ 加前导 0
- PERFORM. dele_zero CHANGING <XXXXX>. ” -- 去掉前导 0
- *&---------------------------------------------------------------------*
- *& Form ADD_ZERO
- *&---------------------------------------------------------------------*
- * text
- *----------------------------------------------------------------------*
- FORM. add_zero CHANGING p_in.
- CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
- EXPORTING
- input = p_in
- IMPORTING
- output = p_in.
- ENDFORM. " ADD_ZERO
- *&---------------------------------------------------------------------*
- *& Form DELE_ZERO
- *&---------------------------------------------------------------------*
- * text
- *----------------------------------------------------------------------*
- FORM. dele_zero CHANGING p_out.
- CALL FUNCTION 'CONVERSION_EXIT_ALPHA_OUTPUT'
- EXPORTING
- input = p_out
- IMPORTING
- output = p_out.
- ENDFORM. " DELE_ZERO
ABAP 中去掉前导零问题
最新推荐文章于 2024-06-18 14:21:03 发布
![](https://img-home.csdnimg.cn/images/20240711042549.png)