登录  
 加关注
   显示下一条  |  关闭
温馨提示!由于新浪微博认证机制调整,您的新浪微博帐号绑定已过期,请重新绑定!立即重新绑定新浪微博》  |  关闭

原来为了你

我的人生就是要一次次的超越

 
 
 

日志

 
 
 
 

在选择屏幕上 set ps-status 2  

2011-01-27 11:05:05|  分类: ABAP屏幕操作 |  标签: |举报 |字号 订阅

  下载LOFTER 我的照片书  |

report  ztest_pfstatus_2   no standard page heading.

*—Selection screen fields

tables : sscrfields.

*—Datat and types

data:

  gc_name    type  string,
  gv_type    type  char1. "'1': MM02; '2': SE16;'3':Execute

data it_ucomm type table of sy-ucomm.
parameter: p_name type char100.
*—Add 3 Custom-buttons in application bar

selection-screen: function key 1,
                  function key 2,
                  function key 3.
load-of-program.
initialization.

*—output
at selection-screen output.

*—Set PF-status

  "Exclude "ONLI”
  append  'ONLI' to it_ucomm.
  call function 'RS_SET_SELSCREEN_STATUS'
    exporting
      p_status  = sy-pfkey
    tables
      p_exclude = it_ucomm.



*—Set the Text.

  sscrfields-functxt_01 = 'Go to MM02'.

  sscrfields-functxt_02 = 'Go to SE16'.

  sscrfields-functxt_03 = 'Execute the report'.



at selection-screen.

*—Function code in Selection-screen

  case sscrfields-ucomm.

    when 'FC01'.

      gv_type = '1'.
      sscrfields-ucomm = 'ONLI'.

    when 'FC02'.

      gv_type = '2'.
      sscrfields-ucomm = 'ONLI'.

    when 'FC03'.

      gv_type = '3'.
      sscrfields-ucomm = 'ONLI'.

  endcase.



start-of-selection.

*—Set PF-status

  set pf-status 'OUTPF'.

*—output

  case gv_type.

    when '1'.                                               "MM01

*—popup to display MM01

      call function 'POPUP_TO_DISPLAY_TEXT'
        exporting
          titel        = 'You will be navigated to MM02'
          textline1    = p_name
          textline2    = 'is the Selected Material number'
          start_column = 25
          start_row    = 6.

*—SPA: Material number

      set parameter id 'MAT' field p_name.
      call transaction 'MM02'.

    when '2'.                                               "SE16

*—popup to display SE16

      call function 'POPUP_TO_DISPLAY_TEXT'
        exporting
          titel        = 'You will be navigated to SE16'
          textline1    = p_name
          textline2    = 'is the Selected table'
          start_column = 25
          start_row    = 6.

*—SPA: Material number

      set parameter id 'DTB' field p_name.
      call transaction 'SE16'.

    when '3'. "Execute the report

      write:/ 'Result: Your input parameter is:', 30 p_name.

  endcase.



at user-command.

*—Sy-ucomm

  case sy-ucomm.

    when 'SPOOL'.

*—popup to display SE16

      call function 'POPUP_TO_DISPLAY_TEXT'
        exporting
          titel        = 'Information'
          textline1    = 'You checked the button "Spool"'
          start_column = 25          "textline2 = 'is the Selected table'
          start_row    = 6.

  endcase.

  评论这张
 
阅读(467)| 评论(0)

历史上的今天

评论

<#--最新日志,群博日志--> <#--推荐日志--> <#--引用记录--> <#--博主推荐--> <#--随机阅读--> <#--首页推荐--> <#--历史上的今天--> <#--被推荐日志--> <#--上一篇,下一篇--> <#-- 热度 --> <#-- 网易新闻广告 --> <#--右边模块结构--> <#--评论模块结构--> <#--引用模块结构--> <#--博主发起的投票-->
 
 
 
 
 
 
 
 
 
 
 
 
 
 

页脚

网易公司版权所有 ©1997-2018