Your SlideShare is downloading. ×
0
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Abap slide class3
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

Abap slide class3

697

Published on

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
697
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
63
Comments
0
Likes
0
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. ABAP workshop Date: 10/28/2009 **DRAFT**
  • 2. Topics <ul><li>Field, Data Element and Domains </li></ul><ul><li>Flow Events </li></ul><ul><li>Input Help (List of Values) –demo/coding </li></ul><ul><li>Field Help (F1 Help) –demo/coding </li></ul><ul><li>Understanding Menu Bar, Application Toolbar and Function keys </li></ul><ul><li>Menu Control and Function Keys </li></ul><ul><li>Context Menu </li></ul><ul><li>Title Bar </li></ul><ul><li>Demo </li></ul><ul><li>Hands-on Practice </li></ul>
  • 3. Data Element &amp; Domains of Fields <ul><li>Domain depicts the technical attributes of a field </li></ul><ul><ul><li>its data type, field length, no. of decimal places, appearance on the screen </li></ul></ul><ul><li>Data Element denotes the semantic attributes </li></ul><ul><ul><li>short description, label names for a field that uses this. </li></ul></ul><ul><li>Data Elements are directly attached to the Fields </li></ul><ul><li>Data Element has an underlying Domain (optional) </li></ul><ul><li>Domains are not directly attached to the fields </li></ul><ul><li>A single Domain can be under many Data Elements. </li></ul><ul><li>Within Domain - value range of a field can be described. Whereas within the Data Element parameter id and search help for a particular field can be assigned. </li></ul>Domain Data Element Field Data Element Field
  • 4. Flow Events <ul><li>PROCESS BEFORE OUTPUT (PBO) </li></ul><ul><ul><li>Fires before a screen is displayed. Can be used to initialize fields. </li></ul></ul><ul><li>PROCESS AFTER INPUT (PAI) </li></ul><ul><ul><li>Fires on an user action (menu/buttons/function-keys) </li></ul></ul><ul><li>PROCESS ON VALUE REQUEST (POV) </li></ul><ul><ul><li>Fires when a set of possible values is requested (F4) </li></ul></ul><ul><li>PROCESS ON HELP REQUEST (POH) </li></ul><ul><ul><li>Fires when general help is requested (F1) </li></ul></ul>
  • 5. Input Help (List of Values) <ul><li>1) Fixed Value (DOMAIN LEVEL) - Hard coded list in Data Dictionary </li></ul><ul><ul><li>Using domain (of the Data Element) of the field </li></ul></ul><ul><li>2) Check Tables (FIELD LEVEL) </li></ul><ul><ul><li>Specifying the Check table on the Field level </li></ul></ul><ul><li>3) Assigning the &amp;quot;Search Help&amp;quot; repository object (DATA ELEMENT LEVEL) </li></ul><ul><ul><li>Create a &amp;quot;Search Help&amp;quot; Object [as an independent step] and then assign it to data element of the field. </li></ul></ul><ul><li>4) Assigning the &amp;quot;Search Help&amp;quot; repository object (SCREEN ELEMENT LEVEL) </li></ul><ul><ul><li>Create a &amp;quot;Search Help&amp;quot; Object [as an independent step] and then assign it to dynpro screen element in screen painter. </li></ul></ul><ul><li>5) Self defined Dropdown List Boxes (SCREEN ELEMENT LEVEL) </li></ul><ul><ul><li>Most flexible but requires simple SQL to populate the list. </li></ul></ul>
  • 6. (1) Fixed Value (Domain Level) Domain of the Data Element Data Element of a Field
  • 7. (2) Check Tables (Field Level) Click on the Foreign Keys Icon
  • 8. (3 &amp; 4) Search Help (Object) Create ‘ Srch Helps’ Object(s) And attach to the Data Element Or attach directly to the Dynpro field LPos: Field Order SPos: Search Order
  • 9. Search Help Field Order LPos: Field Order SPos: Search Order
  • 10. (5) Self defined Dropdown MODULE create_dropdown_box INPUT. dynpro_utilities1=&gt;value_help( ). ENDMODULE. … DATA city_list TYPE STANDARD TABLE OF city_line. SELECT distinct ZCITY ZCITYDESCR from ZCITY_TBL into corresponding fields of table city_list where ZCITY like &apos;%O%&apos; order by ZCITY. CALL FUNCTION &apos; F4IF_INT_TABLE_VALUE_REQUEST &apos; EXPORTING retfield = &apos;ZCITY&apos; value_org = &apos;S&apos; TABLES value_tab = city_list EXCEPTIONS … Select Listbox or Listbox with key
  • 11. Field Help (F1 Help) <ul><li>1) Documentation - (only one) can be attached to the Data Element of the Field needing help documentation. </li></ul><ul><li>2) Additional Documentation - (multiple can be attached to the Data Element of the Field needing help ‘additional documentation’), Dynpro screen field can call just one - the one relevant to its context using ‘ PROCESS ON HELP-REQUEST’ Flow Logic . </li></ul><ul><li>PROCESS ON HELP-REQUEST. (assuming 0001 and 0002 are ‘additional documentation’ help is entered/exists) </li></ul><ul><ul><li>FIELD ZBC400_S_HDR_CURR-CITYTO WITH &apos;0001&apos;. </li></ul></ul><ul><ul><ul><ul><ul><li>Or </li></ul></ul></ul></ul></ul><ul><ul><li>FIELD ZBC400_S_HDR_CURR-CITYTO WITH &apos;0002&apos;. etc </li></ul></ul><ul><li>3) Uses the Process on Help Request (POH) event. </li></ul>
  • 12. Field Help - Documentation Click here in Change Mode to modify (display mode shown) Data Element
  • 13. Field Help - Additional Documentation PROCESS ON HELP-REQUEST. FIELD field1 WITH &apos;0001&apos;. Or FIELD field1 WITH &apos;0002&apos;. Click here. Add as many as you wish Data Element Call any one Additional help
  • 14. Menu Control <ul><li>Create GUI Status object (Interface Component) </li></ul><ul><li>Command: SET PF-STATUS &apos;ZTEST1&apos;. </li></ul><ul><li>Each screen can have same or different menu (set this in PROCESS BEFORE OUTPUT) </li></ul><ul><li>Various menus are: Menu Bar, Standard Tool Bar, Application Toolbar </li></ul><ul><li>Function Keys are generally related to Menu </li></ul><ul><li>Context Menu is inherited from Function Keys,so is same for all fields on screen by default, but… </li></ul><ul><li>Context Menu – each field can be made different </li></ul><ul><li>(ZWRKSHP_010 and ZWRKSHP_010A) </li></ul>
  • 15. Bars in the SAP GUI Menu Bar Standard Tool Bar Title Bar Application Toolbar Related Item Function Keys F1, F2…
  • 16. Menu Painter
  • 17. Menu Painter GUI Status -&gt; ZTEST1 Note: Standard tool bar is shown at the top of the Function Keys Setup! Screen 1/2 Screen 2/2
  • 18. Function Keys <ul><li>The following Function Keys are reserved and are handled at run time </li></ul><ul><ul><ul><li>F1 (field help), </li></ul></ul></ul><ul><ul><ul><li>F4 (Input Help) </li></ul></ul></ul><ul><ul><ul><li>F10 (positions the cursor in the (top) menu bar) </li></ul></ul></ul><ul><li>Double Click automatically gets the functionality of whatever F2 is setup to do – applies to all fields by default. (see subsequent slides) </li></ul><ul><li>F2 or Double Click can be setup so that different logic can be mapped to individual fields (see ZWRKSHP_010C &amp; subsequent slides) </li></ul>
  • 19. Double Click (all fields) <ul><li>When we map a/any functionality to F2 , the same functionality is automatically executed when we Double Click the object. </li></ul><ul><li>Example: If we set the F2 to say “BACK1” (also the Function code), the F2 as well as the Double Click get the functionality from the usual ABAP CASE statement logic. </li></ul>… . CASE ok_code. When &apos;BACK&apos; or &apos;BACK1&apos;. SET SCREEN 100. … .
  • 20. Double Click (individual fields) <ul><li>The Function Code for F2 is set to CS (CURSOR-SELECTION) and TYPE to S (System Function). In PAI use the FIELD statement to call a module. </li></ul><ul><li>… </li></ul><ul><li>PROCESS AFTER INPUT. </li></ul><ul><li>FIELD Field1 MODULE C1 AT CURSOR-SELECTION. </li></ul><ul><li>FIELD Field2 MODULE C2 AT CURSOR-SELECTION. </li></ul>Actual module defn: MODULE C1 INPUT. CALL TRANSACTION &apos;SE13&apos;. ENDMODULE.
  • 21. Context Menu <ul><li>The Context Menu for a SCREEN is ‘automatically’ defaulted from the ‘ function keys ’ MENU setup done using menu designer – i.e., GUI STATUS </li></ul><ul><li>The Context Menu for individual fields is done using the ON_CTMENU_ field as explained in the subsequent slide. </li></ul>
  • 22. Context Menu (of field) <ul><li>Using the ON_CTMENU_ field of screen Elements </li></ul><ul><li>FORM on_ctmenu_my_input2 USING l_menu TYPE REF TO cl_ctmenu. </li></ul><ul><li>CALL METHOD l_menu-&gt;add_function </li></ul><ul><li>EXPORTING fcode = &apos;MY_CONTEXT_MENU7’ </li></ul><ul><li>text = &apos;My Context Menu 7 &apos;. </li></ul><ul><li>… </li></ul><ul><li>CASE save_ok . </li></ul><ul><li>… </li></ul><ul><li>WHEN &apos;MY_CONTEXT_MENU7&apos;. </li></ul><ul><li>CALL TRANSACTION &apos;SE92&apos;. </li></ul><ul><li>… </li></ul><ul><li>ENDCASE. </li></ul>
  • 23. Title Bar <ul><li>THE GUI TITLE is Interface Component </li></ul><ul><li>SET TITLEBAR title. &gt;&gt; Command </li></ul>Create Here Use/Call Here
  • 24. Upcoming Topics <ul><li>Data Clusters </li></ul><ul><li>File Access </li></ul><ul><li>Authorization Checks </li></ul><ul><li>Lock Concept and Enqueue </li></ul>

×