关闭

F4 help functionality for a dynpro screen field using the PROCESS ON VALUE-REQUEST statement

标签: dictionarymoduletablereferencefunctioninput
1675人阅读 评论(0) 收藏 举报
分类:

Pressing the F4 button on a dynpro screen field brings up a list of possible values you can enter into that field. This list of values is usually derived from the domain of the data dictionary definition the screen field is based on. Alternatively if you do not want this to happen or if the field does not reference a data dictionary field the F4 help functionality can be created manually. This is done by creating your own bespoke ABAP code and via the PROCESS ON VALUE-REQUEST event assigning it to the relevant screen field.

The below code shows you how to activate the PROCESS ON VALUE-REQUEST event for a specific field抯 F4 value help functionality. It then shows you how to point this event to your bespoke ABAP code, which will display the value help to the user. Finally it shows you how to return the value select by the user to the dynpro screen field.

* Screen flow logic........

PROCESS BEFORE OUTPUT.
*MODULE PBO_MODULE.

PROCESS AFTER INPUT.
*MODULE PAI_MODULE.

PROCESS ON VALUE-REQUEST. "F4
  FIELD EKPO-EBELP MODULE help_ekpo.

 

 

* populate screen field from within PROCESS ON VALUE-REQUEST(F4) call
*&------------------------------------------------------------------*
*&      Module  help_responsibility  INPUT
*&------------------------------------------------------------------*
*       text
*-------------------------------------------------------------------*
MODULE help_ekpo INPUT.


**Transport values to table dynpro/screen table control
  DATA: l_stepl LIKE  sy-stepl,
        l_indx  LIKE  sy-stepl.
  DATA: dynpfields        LIKE dynpread OCCURS 5 WITH HEADER LINE.

* Adjust for scroling within table control
  CALL FUNCTION 'DYNP_GET_STEPL'
    IMPORTING
      povstepl        = l_stepl
    EXCEPTIONS
      stepl_not_found = 0
      OTHERS          = 0.

  l_indx = tc_ekpotable-top_line + l_stepl - 1.
          "tc_ekpotable should already have been declared

  REFRESH dynpfields.
  CLEAR   dynpfields.
  dynpfields-fieldname  = 'EKPO-EBELN'.
  dynpfields-fieldvalue = '00010'   "wa_ekpo-ebeln.
  dynpfields-stepl      = l_stepl.
  APPEND dynpfields.
  dynpfields-fieldname  = 'EKPO-EBELP'.
  dynpfields-fieldvalue = '00020'   "wa_ekpo-ebelp.
  dynpfields-stepl      = l_stepl.
  APPEND dynpfields.

  CALL FUNCTION 'DYNP_VALUES_UPDATE'
    EXPORTING
      dyname     = 'SAPLZZ_EKKO'    "Program name
      dynumb     = '0100'           "Screen number
    TABLES
      dynpfields = dynpfields
    EXCEPTIONS
      OTHERS     = 0.
ENDMODULE.                 " help_ekpo  INPUT

 

 

0
0
查看评论

F4 help functionality for a dynpro screen field using the PROCESS ON VALUE-REQUEST statement

Pressing the F4 button on a dynpro screen field brings up a list of possible values you can enter into that field. This list of values is usually deri...
  • champaignwolf
  • champaignwolf
  • 2016-08-04 21:07
  • 308

Dynpro F4的实现测试

屏幕中: PROCESS BEFORE OUTPUT. *&SPWIZARD: PBO FLOW LOGIC FOR TABLECONTROL 'TBL'   MOD...
  • zhongguomao
  • zhongguomao
  • 2015-02-10 14:32
  • 994

在PROCESS ON VALUE-REQUEST事件中获取屏幕值

在某项目中,需要用Search Help类似的功能弹出工厂信息,然后回填到字段中,在输入工厂时要根据输入的值来弹出某一个工厂,在PROCESS ON VALUE-REQUEST事件中捕捉不到屏幕的值,为了解决此问题,可以通过Call 一个Function来动态取到屏幕的值,代码如下: DATA:&...
  • champaignwolf
  • champaignwolf
  • 2013-04-21 20:14
  • 2082

f4 OF DATE FIELD IN DYNPRO PROGRAME

 如果使用数据字典中日期类型的字段定义,会有自动的F4帮助,但若使用程序中定义的日期类型字段,则不会有自动的F4帮助,需要手工添加: 1, 在搜索帮助属性中添加 F4_TSEGTIMLOC 2, 在POV中生成   call function...
  • precipitant
  • precipitant
  • 2014-12-30 22:41
  • 523

ABAP AT SELECTION-SCREEN ON VALUE-REQUEST / PROGRESS ON VALUE-REQUEST

DYNP_VALUES_READ & F4IF_INT_TABLE_VALUE_REQUEST
  • balderzwz
  • balderzwz
  • 2010-07-30 16:10
  • 3987

关于SAP F4 Search Help Exit Module

<br />1. 机能作用<br />                   Search Hel...
  • Chuckth
  • Chuckth
  • 2010-07-15 12:50
  • 3625

C#中using关键字的使用介绍

对于using关键字,可能大家比较熟悉的是引入包的功能如代码:using System;还有一种方法和上面的使用方法较类似,只是我们可以指定一个别名,代码如:using INet = System.Net;最后一种用法则主要用于释放对象占用的资源的,代码如下:using (ClassC c = ne...
  • Haliput
  • Haliput
  • 2008-07-07 22:00
  • 1159

xorg初始化过程,没有配置文件,用默认值

[    32.314] (==) No screen section available. Using defaults. [    32.314] (**) |-->Screen "Default Screen Sec...
  • sitelist
  • sitelist
  • 2015-02-14 21:36
  • 1207

There is a process already using the admin port 4848

There is a process already using the admin port 4848 -- it probably is another instance of a GlassFish server. Command start-domain failed. 如果启动...
  • weigotopro
  • weigotopro
  • 2012-07-15 18:12
  • 431

Get the F4 help of a field based on the value of another field in the selction screen(联动的搜索帮助)

F4 help , search help, DYNP_VALUES_READ, F4IF_INT_TABLE_VALUE_REQUEST
  • fengyan5022
  • fengyan5022
  • 2013-10-15 08:32
  • 557
    个人资料
    • 访问:964767次
    • 积分:15035
    • 等级:
    • 排名:第916名
    • 原创:406篇
    • 转载:324篇
    • 译文:0篇
    • 评论:74条
    文章存档
    最新评论