关于write输出

来源:互联网 发布:淘宝客增加权重吗 编辑:程序博客网 时间:2024/06/09 17:10

*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*  -->  p1        text
*  <--  p2        text
*----------------------------------------------------------------------*
FORM get_write .

  DATA n TYPE i VALUE 123.
****
  FORMAT COLOR COL_HEADING INTENSIFIED ON."grayish blue
  WRITE : / n.
  WRITE spfli-fltime.

  FIELD-SYMBOLS <cf> TYPE ANY.
  ASSIGN 'NEW YORK' TO <cf>.
  WRITE <cf>.

  WRITE: '---->', spfli-distance.

  WRITE: text-001, spfli-arrtime.
  WRITE: 'Time:'(001), spfli-arrtime.
  SKIP.
  DATA: word(16) VALUE '0123456789ABCDEF',
        col TYPE i VALUE 5,
        len TYPE i VALUE 10.
  WRITE AT / word.          "new line
  SKIP.

  FORMAT COLOR COL_NORMAL INTENSIFIED ON.
  WRITE AT 5 word.           "column 5 ****0123456789ABCDEF
  SKIP.

  FORMAT COLOR COL_TOTAL INTENSIFIED ON.
  WRITE AT (10) word.       "output length 10
  SKIP.

  FORMAT COLOR COL_KEY INTENSIFIED ON.
  WRITE AT /5(10) word.     "new line, column 5, length 10
  SKIP.

  FORMAT COLOR COL_POSITIVE INTENSIFIED ON.
  WRITE AT col word.        "column = contents of COL
  SKIP.

  FORMAT COLOR COL_NEGATIVE INTENSIFIED ON.
  WRITE AT (len) word.      "output length = contents of LEN
  SKIP.

  FORMAT COLOR COL_GROUP INTENSIFIED ON.
  WRITE AT /col(len) word.  "new line, column = contents of COL
  "output length = contents of LEN

ENDFORM.                    " get_write

 

 

原创粉丝点击