美文网首页
ALV表头样式

ALV表头样式

作者: Mmm_余安 | 来源:发表于2017-06-06 16:18 被阅读22次
例图.png


"最后一列要用

  g_text = &3.
  call method document->add_text  "插入文本
    exporting
      text         = g_text
      sap_emphasis = &2.
  call method document->add_gap "插入位置
    exporting
      width = &1.
END-OF-DEFINITION.```

```DATA:g_text TYPE sdydo_text_element.
  DATA:lv_p TYPE i.
  DATA:lv_string TYPE string.
  DATA:lv_string1 TYPE string.```

``  lv_string = '<html>'.``

  ```  CALL METHOD document->html_insert
    EXPORTING
      contents = lv_string
    CHANGING
      position =  lv_p.``

  ``` CONCATENATE '<DIV STYLE="padding-left:350px">'
              'xxxx ' '</div>'  INTO lv_string. "自定义样式
    CALL METHOD document->html_insert
    EXPORTING
      contents = lv_string
    CHANGING
      position =  lv_p.```

```CONCATENATE  '<H3 STYLE="padding-left:400px">' '利 润 表 ' '</H3>'  INTO lv_string1.
    CALL METHOD document->html_insert
    EXPORTING
      contents = lv_string1
    CHANGING
      position =  lv_p.```


  ```lv_string1 = '报表编号 Z2 ' .
    CALL METHOD document->html_insert
    EXPORTING
      contents = lv_string1
    CHANGING
      position =  lv_p.```

```  " CALL METHOD document->new_line.""换行
   CALL METHOD document->new_line.
   mcr_html_field 2   ' '  '单位:'.
   mcr_html_field 55   'KEY'  gs_t001-butxt.```

 ```  mcr_html_field 2   ' '  '日期:'.
   mcr_html_field 55   'KEY'  zdata4.``

  ``` mcr_html_field 2   ' '  '单位:元'."STRONG 加粗  EMPHASIS 斜体
   mcr_html_field 70   'KEY'  ' '.```

相关文章

网友评论

      本文标题:ALV表头样式

      本文链接:https://www.haomeiwen.com/subject/bjtnfxtx.html