技术开发 频道

ABAP的代码规范标准

    【IT168 技术文章】

    ABAP代码编写要求

    1、单元格式

    ************************************************************************

    * Copyright 2006 C-Bons Wuhan                                          *

    * All Rights Reserved                                                  *

    *----------------------------------------------------------------------*

    * Program Name : ZXXXXX                                                *

    * Project      : C-Bons SAP Implementation Project                     *

    * Program Title:                                                       *

    * Created by   : DEVXX                                                 *

    * Created on   : 2006/02/18                                            *

    * Version      : 1.0                                                   *

    * Function Description:                                                *

    *                                                                      *

    *----------------------------------------------------------------------*

    * Data Table List:                                                    *

    *如维护操作的表,数据计算来源等表

    *----------------------------------------------------------------------*

    * Refrence Table List:                                                 *

    *如联络处描叙,输入帮助等用到的表

    *----------------------------------------------------------------------*

    * Modification Log:                                                    *

    ************************************************************************

    * Date        Programmer     Correction Number      DesingDoc Number   *

    * YYYY/MM/DD  XXXXXXXX       DEVK9nnnnnn                               *

    ************************************************************************

    注意:版本修改信息中设计文档版本有对应的文档则必须填写。

    单元命名规则

    对于复杂的程序,可以将其编写为多个INCLUDE,不同作用的代码放在不同的INCLUDE中,各个INCLUDE的名称按下表编写

    代码的作用 单元名称

    Events(TOP-OF-PAGE等) ZXXXXE01

    Subroutines(Form routines) ZXXXXF01

    PAI Modules ZXXXXI01

    PBO Modules ZXXXXO01

    Global Data ZXXXXTOP

    Input Help ZXXXXH01

    其中:ZXXXX为程序名。

    事件代码必须遵循编写顺序

    Initialization

    At Selection-Screen OutPut

    At Selection-Screen

    START-OF-Selection

    At Select-Screen on XXXX

    At Select-Screen on value request for XXXXX

    At Select-Screen on help request for XXXXX

    共用函数的格式

    ************************************************************************

    * Function Name : XXXXX                                                    *

    * Created by   : DEVXX                                                 *

    * Created on   : 2006/02/18                                            *

    * Function Description:                                                *

    *                                                                      *

    *----------------------------------------------------------------------*

    *参数说明                   *

    *                                                                      *

    *----------------------------------------------------------------------*

    * Modification Log:                                                    *

    ************************************************************************

    * Date        Programmer   Description           *

    * YYYY/MM/DD  XXXXXXXX                                                 *

    子函数的格式

    ************************************************************************

    * Form Name : XXXXX                                                    *

    * Created by   : DEVXX                                                 *

    * Created on   : 2006/02/18                                            *

    * Form Description:                                                *

    *                                                                      *

    *----------------------------------------------------------------------*

    *参数说明                   *

    *                                                                      *

    *----------------------------------------------------------------------*

    * Modification Log:                                                    *

    ************************************************************************

    * Date        Programmer   Description           *

    * YYYY/MM/DD  XXXXXXXX                                                 *

    ************************************************************************

   

0
相关文章