thitima's blog
How to set cursor field on selection-screen in ABAP/4
You can set cursor field on selection-screen by applying statement ’SET CURSOR FIELD ...’ in event INITIALIZATION.
Example
PARAMETERS: P_FLD1(20) TYPE C,
P_FLD2 TYPE I.
INITIALIZATION.
SET CURSOR FIELD ’P_FLD2’.
The output is:
How to create parameter as listbox in ABAP/4
You can create parameter as listbox by applying statement ’PARAMETER
Example
TYPE-POOLS: vrm.
DATA: it_list TYPE VRM_VALUES,
list_value TYPE VRM_VALUE.
PARAMETERS: p_list(20) TYPE C AS LISTBOX VISIBLE LENGTH 15.
AT SELECTION-SCREEN OUTPUT.
list_value-key = ’AAAA’.
list_value-text = ’AAAA Show Text’.
append list_value to it_list.
list_value-key = ’AAAB’.
list_value-text = ’AAAB Show Text’.
append list_value to it_list.
list_value-key = ’AAAC’.
list_value-text = ’AAAC Show Text’.
append list_value to it_list.
list_value-key = ’AAAD’.
list_value-text = ’AAAD Show Text’.
append list_value to it_list.
CALL FUNCTION ’VRM_SET_VALUES’
EXPORTING
ID = ’P_LIST’
VALUES = it_list
EXCEPTIONS
ID_ILLEGAL_NAME = 1
OTHERS = 2
.
IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
START-OF-SELECTION.
WRITE:/ ’P_LIST parameter have value: ’, p_list.
- Add new comment
- Read more
- 8232 reads
Create pushbutton in selection screen in ABAP/4
You can create the pushbutton in your selection screen by applying statement ’SELECTION-SCREEN PUSHBUTTON ...’.
Example
TABLES sscrfields.
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE TEXT-001.
PARAMETERS: p_fld1 TYPE i DEFAULT 1,
p_fld2 TYPE i DEFAULT 2.
SELECTION-SCREEN PUSHBUTTON /1(10) Execute USER-COMMAND EXEC.
SELECTION-SCREEN END OF BLOCK b1.
INITIALIZATION.
Execute = ’Testing’.
AT SELECTION-SCREEN.
IF sscrfields-ucomm = ’EXEC’.
MESSAGE I398(00) WITH ’Testing Pushbutton Action between value’
p_fld1 ’and’ p_fld2.
ENDIF.The output is:
When you select the pushbutton, the output is:
- Add new comment
- Read more
- 8743 reads
ควรรู้ไว้..วิธีสังเกตอาการเบื้องต้นของมะเร็ง
ที่มา: Forward Mail
วิธีสังเกตอาการเบื้องต้นของมะเร็งชนิดต่างๆ
อาการของการเกิดมะเร็งในอวัยวะต่าง ๆ ของร่างกาย
- มะเร็งปากมดลูก อาการ มีเลือดออกจากช่องคลอดทั้งๆ ที่ไม่ใช่เวลารอบเดือนปกติของคุณ อาการเจ็บปวดและมีเลือดออกหลังจากมีเพศสัมพันธ์ หากพบว่ามีสิ่งเหล่านี้เกิดขึ้น การตรวจโดยขูดเนื้อเยื่อจากบริเวณดังกล่าวไปตรวจด้วยกล้องจุลทรรศน์จะรู้ได้
- Add new comment
- Read more
- 10157 reads
ABAP/4 Example Code: How to generate graph 3D by ABAP/4
We can generate graph 3D by applying function module ’GRAPH_3D’.
Example
DATA: BEGIN OF itab OCCURS 0,
text(20) TYPE C,
value1 TYPE i,
value2 TYPE i,
value3 TYPE i,
END OF itab.
START-OF-SELECTION.
itab-text = ’COL1’.
itab-value1 = ’20’.
itab-value2 = ’5’.
itab-value3 = ’10’.
APPEND itab.
itab-text = ’COL2’.
itab-value1 = ’5’.
itab-value2 = ’15’.
itab-value3 = ’30’.
APPEND itab.
itab-text = ’COL3’.
itab-value1 = ’80’.
itab-value2 = ’50’.
itab-value3 = ’40’.
APPEND itab.
itab-text = ’COL4’.
itab-value1 = ’35’.
itab-value2 = ’15’.
itab-value3 = ’5’.
APPEND itab.
CALL FUNCTION ’GRAPH_3D’
EXPORTING
* AUTO_CMD_1 = ’ ’
* AUTO_CMD_2 = ’ ’
* DIM1 = ’ ’
* DIM2 = ’ ’
* TYPE = ’ ’
* DISPLAY_TYPE = ’ ’
* INBUF = ’ ’
* INFORM = ’ ’
* MAIL_ALLOW = ’ ’
* PWDID = ’ ’
* SET_FOCUS = ’x’
* SO_CONTENTS = ’ ’
* SO_RECEIVER = ’ ’
* SO_SEND = ’ ’
* SO_TITLE = ’ ’
* STAT = ’ ’
* SUPER = ’ ’
* TIMER = ’ ’
TITL = ’Testing graph 3D’
* VALT = ’ ’
* WDID = ’ ’
* WINID = ’ ’
* WINPOS = ’ ’
* WINSZX = ’50’
* WINSZY = ’50’
* X_OPT = ’ ’
* NOTIFY = ’ ’
* IMPORTING
* B_KEY =
* B_TYP =
* CUA_ID =
* MOD_COL =
* MOD_ROW =
* MOD_VAL =
* M_TYP =
* RBUFF =
* RWNID =
TABLES
DATA = itab
.
- Add new comment
- Read more
- 1719 reads
ABAP/4 Example Code: How to generate graph 2D by ABAP/4
We can generate graph 2D by applying function module ’GRAPH_2D’.
Example
DATA: BEGIN OF itab OCCURS 0,
text(20) TYPE C,
value TYPE i,
END OF itab.
START-OF-SELECTION.
itab-text = ’COL1’.
itab-value = 50.
APPEND itab.
itab-text = ’COL2’.
itab-value = 100.
APPEND itab.
itab-text = ’COL3’.<
- Add new comment
- Read more
- 2763 reads
Recent comments
3 years 33 weeks ago
3 years 38 weeks ago
3 years 39 weeks ago
3 years 39 weeks ago
3 years 40 weeks ago
3 years 42 weeks ago
3 years 42 weeks ago
3 years 42 weeks ago
3 years 42 weeks ago
3 years 43 weeks ago