Need an Exit  to find ZIP code of Delivery address in PO.

Hi Experts,
I am an abaper & i am tryin to connect Taxwar & SAP during the prcess of PO creation.
Now my req is to find if the plant address & the Delivery address are different ( need to compare the ZIP codes).
Can anyone sugget an exit where i can do thi comparison?
regards,
Kevin.

Hi kevin,
Use the below given code, after executing this it will ask the transaction code of which u are requiring exit, give the tcode over there u can get exits available for that tcode.
ABLES : tstc, "SAP Transaction Codes
         tadir, "Directory of Repository Objects
       modsapt, "SAP Enhancements - Short Texts
        modact, "Modifications
         trdir, "System table TRDIR
         tfdir, "Function Module
       enlfdir, "Additional Attributes for Function Modules
        tstct, "Transaction Code Texts
       RSSTCD,
        TRKEY.
*& Definition of Types                                                  *
TYPES: BEGIN OF t_badi_list,
                obj_name TYPE sobj_name ,
                devclass TYPE devi_class ,
                 dlvunit TYPE dlvunit,
                imp_name TYPE exit_imp ,
                packname TYPE devclass ,
                dlvunit2 TYPE dlvunit,
                    text TYPE sxc_attrt-text,
      END OF t_badi_list.
TYPES: BEGIN OF t_badi_list2,
                obj_name TYPE sobj_name ,
                devclass TYPE devi_class ,
                 dlvunit TYPE dlvunit,
       END OF t_badi_list2.
*& Data Declaration                                                     *
DATA: lt_badi_list TYPE TABLE OF t_badi_list,
     lt_badi_list2 TYPE TABLE OF t_badi_list2,
      ls_badi_list TYPE t_badi_list OCCURS 0 WITH HEADER LINE,
     ls_badi_list2 TYPE t_badi_list2.
RANGES: r_badi FOR tadir-obj_name ,
       rt_badi FOR tadir-obj_name .
*& Variables                                                            *
DATA : jtab LIKE tadir OCCURS 0 WITH HEADER LINE,
    P_TRKEY LIKE TRKEY.
DATA : field1(30),
       BADINAME(20),
       COUNT TYPE P.
DATA : v_devclass LIKE tadir-devclass,
      p_devclass LIKE tadir-devclass,
      p_old_langu LIKE sy-langu,
      p_mod_langu LIKE sy-langu.
*& Selection Screen Parameters                                          *
SELECTION-SCREEN BEGIN OF BLOCK a01 WITH FRAME TITLE text-001.
SELECTION-SCREEN SKIP.
PARAMETERS : p_tcode LIKE tstc-tcode OBLIGATORY.
SELECTION-SCREEN SKIP.
SELECTION-SCREEN END OF BLOCK a01.
*& Start of report                                                      *
START-OF-SELECTION.
Validate Transaction Code
SELECT SINGLE * FROM tstc WHERE tcode EQ p_tcode.
*Find Repository Objects for transaction code
IF sy-subrc EQ 0.
  SELECT SINGLE * FROM tadir WHERE pgmid = 'R3TR'
                              AND object = 'PROG'
                            AND obj_name = tstc-pgmna.
  MOVE: tadir-devclass TO v_devclass.
  IF sy-subrc NE 0.
This section is used if a FGR is involved\!
    CALL FUNCTION 'RS_ACCESS_PERMISSION'
         EXPORTING
               global_lock = 'X'
                    object = p_tcode
              object_class = 'TRAN'
                      mode = 'SHOW'
         language_upd_exit = 'RS_TRANSACTION_LANGUAGE_EXIT'
   suppress_language_check = space
        IMPORTING
       new_master_language = p_old_langu
     modification_language = p_mod_langu
             transport_key = p_trkey
                  devclass = p_devclass
       EXCEPTIONS
          canceled_in_corr = 1
                    OTHERS = 2.
    IF SY-SUBRC = 0. " Success
      MOVE: p_devclass TO v_devclass.
    ELSE. " For the case that nothing is found\!
      SELECT SINGLE * FROM trdir WHERE name = tstc-pgmna.
      IF trdir-subc EQ 'F'.
        SELECT SINGLE * FROM tfdir WHERE pname = tstc-pgmna.
        SELECT SINGLE * FROM enlfdir WHERE funcname = tfdir-funcname.
        SELECT SINGLE * FROM tadir WHERE pgmid = 'R3TR'
                                    AND object = 'FUGR'
                                  AND obj_name = p_devclass.
        MOVE: tadir-devclass TO v_devclass.
      ENDIF.
    ENDIF.
  ENDIF.
*Find SAP Modifactions
    SELECT * FROM tadir INTO TABLE jtab
                        WHERE pgmid = 'R3TR'
                         AND object = 'SMOD'
                       AND devclass = v_devclass.
    SELECT SINGLE * FROM tstct WHERE sprsl EQ sy-langu
                                 AND tcode EQ p_tcode.
    FORMAT COLOR COL_POSITIVE INTENSIFIED OFF.
    WRITE:/(19) 'Transaction Code - ', 20(20) p_tcode, 45(50) tstct-ttext.
    FORMAT COLOR COL_POSITIVE INTENSIFIED ON.
    SKIP.
    WRITE:/1 'The application area is:', v_devclass.
    SKIP.
    IF NOT jtab[] IS INITIAL.
      WRITE:/(95) sy-uline.
      FORMAT COLOR COL_HEADING INTENSIFIED ON.
      WRITE:/1 sy-vline, 2 'Exit Name', 21 sy-vline, 22 'Description', 95 sy-vline.
      WRITE:/(95) sy-uline.
      LOOP AT jtab.
        SELECT SINGLE * FROM modsapt
                       WHERE sprsl = sy-langu
                          AND name = jtab-obj_name.
        FORMAT COLOR COL_NORMAL INTENSIFIED OFF.
        WRITE:/1 sy-vline, 2 jtab-obj_name HOTSPOT ON, 21 sy-vline , 22 modsapt-modtext,
        95 sy-vline.
      ENDLOOP.
      WRITE:/(95) sy-uline.
      DESCRIBE TABLE jtab.
      SKIP.
      FORMAT COLOR COL_TOTAL INTENSIFIED ON.
      WRITE:/ 'No of Exits:' , sy-tfill.
      SKIP.
      WRITE:/(83) sy-uline.
      FORMAT COLOR COL_HEADING INTENSIFIED ON.
      WRITE:/1 sy-vline, 2 'Badi Name', 22 sy-vline, 23 'Description', 83 sy-vline.
      WRITE:/(83) sy-uline.
select the BAdI Definitions from the tables sxc_exit and sxc_attr
      SELECT tobj_name tdevclass tcdlvunit sximp_name sat~text
                   INTO CORRESPONDING FIELDS OF TABLE lt_badi_list
                   FROM ( ( ( ( tadir AS t
                   INNER JOIN
                     tdevc AS tc ON tdevclass = tcdevclass )
                   INNER JOIN
                     sxc_exit AS sx ON sxexit_name = tobj_name )
                   INNER JOIN
                     sxc_attr AS sa ON sximp_name = saimp_name )
                   INNER JOIN
                     sxc_attrt AS sat ON sximp_name = satimp_name )
                   WHERE t~pgmid = 'R3TR'
                   AND t~object = 'SXSD' "means BAdI
                   AND t~devclass = v_devclass "narrow down seach with Dev.Class
                   AND sat~sprsl = sy-langu.
      SORT lt_badi_list.
      DELETE ADJACENT DUPLICATES FROM lt_badi_list.
create Ranges
      LOOP AT lt_badi_list INTO ls_badi_list .
        r_badi-sign = 'I' .
        r_badi-option ='EQ' .
        r_badi-low = ls_badi_list-imp_name .
        r_badi-high = ls_badi_list-imp_name .
        APPEND r_badi TO rt_badi .
      ENDLOOP.
select the implementations
      SELECT tobj_name tdevclass tc~dlvunit
            INTO CORRESPONDING FIELDS OF TABLE lt_badi_list2
            FROM tadir AS t
            INNER JOIN
              tdevc AS tc ON tdevclass = tcdevclass
            FOR ALL ENTRIES IN rt_badi
            WHERE t~obj_name = rt_badi-low
            AND t~pgmid = 'R3TR'
            AND t~object = 'SXCI'.
      FORMAT COLOR COL_NORMAL INTENSIFIED OFF.
      WRITE:/(83) sy-uline.
      COUNT = '0'.
      LOOP AT lt_badi_list INTO ls_badi_list .
        WRITE:/1 sy-vline, 2 ls_badi_list-obj_name HOTSPOT ON, 22 sy-vline,
              23 ls_badi_list-text, 83 sy-vline.
        COUNT = COUNT + 1.
      ENDLOOP.
      WRITE:/(83) sy-uline.
      DESCRIBE TABLE ls_badi_list.
      SKIP.
      FORMAT COLOR COL_TOTAL INTENSIFIED ON.
      WRITE:/ 'No of BADIs:' , COUNT.
    ELSE.
      FORMAT COLOR COL_NEGATIVE INTENSIFIED ON.
      WRITE:/(95) 'No User Exit exists'.
    ENDIF.
  ELSE.
    FORMAT COLOR COL_NEGATIVE INTENSIFIED ON.
    WRITE:/(95) 'Transaction Code Does Not Exist'.
  ENDIF.
*& Call SMOD or SE18 to lead the user to the selected exit or badi      *
AT LINE-SELECTION.
GET CURSOR FIELD field1.
IF field1(4) EQ 'JTAB'.
  SET PARAMETER ID 'MON' FIELD sy-lisel+1(10).
  CALL TRANSACTION 'SMOD' AND SKIP FIRST SCREEN.
ELSEIF field1(12) EQ 'LS_BADI_LIST'.
  CALL FUNCTION 'SXO_BADI_SHOW'
       EXPORTING
         EXIT_NAME = sy-lisel+1(20)
       EXCEPTIONS
         ACTION_CANCELED
         ACCESS_FAILURE
         BADI_NOT_EXIXTING.
ELSE.
ENDIF.
Regards
Arani Bhaskar

Similar Messages

  • REGEX - find zip code in text

    Hi experts!
    I have to find the zip code (for germany) in a given text. I found 5 digits in my text, but my problem is to ignore numbers which consists of more than 5 digits!
    My first try works for all cases but not for the last one.
    FIND FIRST OCCURRENCE OF REGEX '([0-9]{5})' IN ld_string SUBMATCHES ld_plz.
    D-12345 Mainz -> should match 12345
    D 12345 Mainz -> should match 12345
    12345 Mainz -> should match 12345
    12345Mainz -> should match 12345
    Mainz D-12345  -> should match 12345
    D-123 45 Mainz -> error because of the space between the numbers
    D-12333345 Mainz -> error because only 5 digits are valid for a germany zip code; my REGEX does not work!
    Thanks a lot!
    Regards,
    Florian

    Hi Florian,
    curiosity persists.
    After some playing around I reduced the pattern using Placeholder for any single digit \d. Then I noticed that the 5-digit-sequence will also match 5 digits out of 6, so i used \D Placeholder for any character other than a digit Then I don't know how to recognize (optional) line start or end as alternative to non-digit, so I just enclose the string to be checked into spaces - please suggest a more elegant solution.
    My test form
    FORM regex .
      DATA:
        lv_subm   type string,
        lt_string TYPE TABLE OF string.
      FIELD-SYMBOLS:
        <string>  TYPE string.
      APPEND:
        'D-12345 Mainz' TO lt_string,
        'D 12345 Mainz' TO lt_string,
        '12345 Mainz'   TO lt_string,
        '12345Mainz'    TO lt_string,
        '123456Mainz'    TO lt_string,
        '123 45Mainz'    TO lt_string,
        'Mainz D-12345' TO lt_string.
      LOOP AT lt_string ASSIGNING <string>.
        clear:
          lv_subm.
        CONCATENATE ` ` <string> ` ` into <string>.
        FIND REGEX '\D(\d{5})\D' IN <string> SUBMATCHES lv_subm.
        WRITE: / <string>, 20 'matches', 30 lv_subm,40 'SY-SUBRC=', sy-subrc.
      ENDLOOP.
    ENDFORM.                    " REGEX
    creates this output:
    D-12345 Mainz     matches   12345     SY-SUBRC=     0
    D 12345 Mainz     matches   12345     SY-SUBRC=     0
    12345 Mainz       matches   12345     SY-SUBRC=     0
    12345Mainz        matches   12345     SY-SUBRC=     0
    123456Mainz       matches             SY-SUBRC=     4
    123 45Mainz       matches             SY-SUBRC=     4
    Mainz D-12345     matches   12345     SY-SUBRC=     0
    As I do not fully understand the meaning of FIRST OCCURRENCE, I just removed it.
    Regards,
    Clemens

  • US PY - Changing zip code for perm address in causes error

    Gurus,
    I am trying to change the zip code from 08852 (incorrect) to 10022 (correct) in the permanent address of IT0006.
    I get the following error:
    Data record 0900005500061      9999123120090407000 has grouping value "" instead of "10"
    Any ideas why?
    Thanks,

    Sarika,
    What to check in T5UTF?
    I don't see the NY zip code 10022 there.
    Is this a problem.
    I don't have 207 info type for the pers. ID yet
    Just trying to change the IT006
    Thanks

  • User exit/BADI for Return PO item delivery Address

    Hi Guyz,
    We have a requirement where in when a PO item is marked as return PO item(In ME21n/ME22n/ME23n We have check box at item level) and click on enter/Check/Save, In delivery address of item details we have to populate Vendor address. By default SAP populates Plant address. If we manually give Vendor number in item details=>Delivery address tab then it populates vendor address. We want to automate this functionality.
    Is there any Exit/BADI which serve this purpose.
    Note: We need this functionality for few doc types(i.e PO doc type should also be available in the exit).
    Any ideas could be really helpfull.
    Thanks,
    Vinod.

    Hi,
    there are some user-exit & enhancements....
    MEQUERY1                                Enhancement to Document Overview ME21N/ME51N
    MEVME001                                WE default quantity calc. and over/ underdelivery tolerance
    MM06E001                                User exits for EDI inbound and outbound purchasing documents
    MM06E003                                Number range and document number
    MM06E004                                Control import data screens in purchase order
    MM06E005                                Customer fields in purchasing document
    MM06E007                                Change document for requisitions upon conversion into PO
    MM06E008                                Monitoring of contr. target value in case of release orders
    MM06E009                                Relevant texts for "Texts exist" indicator
    MM06E010                                Field selection for vendor address
    MMAL0001                                ALE source list distribution: Outbound processing
    MMAL0002                                ALE source list distribution: Inbound processing
    MMAL0003                                ALE purcasing info record distribution: Outbound processing
    MMAL0004                                ALE purchasing info record distribution: Inbound processing
    MMDA0001                                Default delivery addresses
    MMFAB001                                User exit for generation of release order
    MRFLB001                                Control Items for Contract Release Order
    MELAB001                                Gen. forecast delivery schedules: Transfer schedule implem.
    AMPL0001                                User subscreen for additional data on AMPL
    LMEDR001                                Enhancements to print program
    LMELA002                                Adopt batch no. from shipping notification when posting a GR
    LMELA010                                Inbound shipping notification: Transfer item data from IDOC
    LMEQR001                                User exit for source determination
    LMEXF001                                Conditions in Purchasing Documents Without Invoice Receipt
    LWSUS001                                Customer-Specific Source Determination in Retail
    M06B0001                                Role determination for purchase requisition release
    M06B0002                                Changes to comm. structure for purchase requisition release
    MEFLD004                                Determine earliest delivery date f. check w. GR (only PO)
    MEETA001                                Define schedule line type (backlog, immed. req., preview)
    ME590001                                Grouping of requsitions for PO split in ME59
    M06E0005                                Role determination for release of purchasing documents
    M06E0004                                Changes to communication structure for release purch. doc.
    M06B0005                                Changes to comm. structure for overall release of requisn.
    M06B0004                                Number range and document number
    M06B0003                                Number range and document number
    Some BADI s:
    ME_PROCESS_PO                           Enhancements for Processing Enjoy Purchase Order: Intern.
    ME_PROCESS_COMP                         Processing of Component Default Data at Time of GR: Customer
    ME_PO_SC_SRV                            BAdI: Service Tab Page for Subcontracting
    ME_PO_PRICING_CUST                      Enhancements to Price Determination: Customer
    ME_PO_PRICING                           Enhancements to Price Determination: Internal
    ME_INFOREC_SEND                         Capture/Send Purchase Info Record Changes - Internal Use
    ME_HOLD_PO                              Hold Enjoy Purchase Orders: Activation/Deactivation
    ME_GUI_PO_CUST                          Customer's Own Screens in Enjoy Purchase Order
    ME_FIELDSTATUS_STOCK                    FM Account Assignment Behavior for Stock PR/PO
    ME_DP_CLEARING                          Clearing (Offsetting) of Down Payments and Payment Requests
    ME_DEFINE_CALCTYPE                      Control of Pricing Type: Additional Fields
    ME_COMMTMNT_REQ_RE_C                    Check of Commitment Relevance of Purchase Requisitions
    ME_COMMTMNT_REQ_RELE                    Check of Commitment Relevance of Purchase Requisitions
    ME_PROCESS_PO_CUST                      Enhancements for Processing Enjoy Purchase Order: Customer
    SMOD_MRFLB001                           Control Items for Contract Release Order
    MM_EDI_DESADV_IN                        Supplementation of Delivery Interface from Purchase Order
    MM_DELIVERY_ADDR_SAP                    Determination of Delivery Address
    ME_WRF_STD_DNG                          PO Controlling Reminder: Extension to Standard Reminder
    ME_TRIGGER_ATP                          Triggers New ATP for Changes in EKKO, EKPO, EKPV
    ME_TRF_RULE_CUST_OFF                    BADI for Deactivation of Field T161V-REVFE
    ME_TAX_FROM_ADDRESS                     Tax jurisdiction code taken from address
    ME_REQ_POSTED                           Purchase Requisition Posted
    ME_REQ_OI_EXT                           Commitment Update in the Case of External Requisitions
    ME_RELEASE_CREATE                       BAdI: Release Creation for Sched.Agrmts with Release Docu.
    ME_PURCHDOC_POSTED                      Purchasing Document Posted
    ME_PROCESS_REQ_CUST                     Enhancements for Processing Enjoy PReqs: Customer
    ME_PROCESS_REQ                          Enhancements for Processing Enjoy PReqs: Internal
    ME_COMMTMNT_PO_REL_C                    Check for Commitment-Relevance of Purchase Orders
    ME_CCP_BESWK_AUTH_CH                    BAdI for authorization checks for procuring plant
    ME_CCP_ACTIVE_CHECK                     BAdI to check whether CCP process is active
    ME_BSART_DET                            Change document type for automatically generated POs
    ME_BAPI_PR_CREATE_02
    ME_BAPI_PR_CREATE_01
    ME_BAPI_PO_CREATE_02
    ME_BAPI_PO_CREATE_01
    ME_BADI_DISPLAY_DOC                     BAdI for Internal Control of Transaction to be Invoked
    ME_ACTV_CANCEL_PO                       BAdI for Activating the Cancel Function at Header Level
    MEGUI_LAYOUT                            BAdI for Enjoy Purchasing GUI
    EXTENSION_US_TAXES                      Extended Tax Calculation with Additional Data
    ARC_MM_EKKO_WRITE                       BAdI: Enhancement of Scope of Archiving (MM_EKKO)
    ARC_MM_EKKO_CHECK                       BAdI: Enhancement of Archivability Check (MM_EKKO)
    ME_CCP_DEL_DURATION                     Calc. of Delivery Duration in CCP Process (Not in Standard)
    ME_COMMTMNT_PO_RELEV                    Check for Commitment-Relevance of Purchase Orders
    ME_COMMITMENT_STO_CH                    BadI for checking if commitments for STOs are active
    ME_COMMITMENT_RETURN                    Commitment for return item
    ME_CIP_REF_CHAR                         Enables Reference Characteristics in Purchasing
    ME_CIP_ALLOW_CHANGE                     Configuration in Purchasing: Changeability Control
    ME_CIN_MM06EFKO                         Copy PO data for use by Country version India
    ME_CIN_LEINRF2V                         BADI for LEINRF03 excise_invoice_details
    ME_CIN_LEINRF2R                         BADI for CIN India - Delivery charges
    ME_CHECK_SOURCES                        Additional Checks in Source Determination/Checking
    ME_CHECK_OA                             Check BAdI for Contracts
    ME_CHECK_ALL_ITEMS                      Run Through Items Again in the Event of Changes in EKKO
    ME_CHANGE_OUTTAB                        Enrich ALV Output Table in Purchasing
    ME_CHANGE_CHARACTER                     Customer-Specific Characteristics for Product Allocation
    No.of Exits:         35
    No.of BADis:         55
    Arunima

  • Post code in delivery address when creating PO

    Hi friends,
    when creating PO, the post code field under delivery address tab is a required field. while some of our delivery address do not has post code. it seems a mandatory filed.
    How could I change it to a optional field.
    Thanks,
    Linda

    Ask your ABAPer to assist you on this.
    Path to Screen Variant
    Choose Basis Components - Application Personalization - Tailoring of Application Transactions - Configure Transaction-Related Display Values for Fields
    Screen variants allow you to simplify screen editing by:
    Inserting default values in fields
    Hiding and changing the ready for input status of fields
    Hiding and changing the attributes of table control columns
    A screen variant contains field values and attribute for exactly one screen. A screen variant may be assigned to multiple transaction variants, however. Screen variants are always cross-client; they may, however, be assigned to a client-specific transaction. They can also be called at runtime by a program. The different possibilities for calling screen variants guarantee great flexibility of use. A specific namespace has been designated for screen variants and they are automatically attached to the Change and Transport System.
    Check following lInk:
    http://wiki.sdn.sap.com/wiki/display/Snippets/TransactionVariant-AStepbyStepGuidefor+Creation
    Thanks & Regards
    JP

  • Nearest search base on Zip Code

    Hey All,
    I need some help for my following requirements -
    -> In my web base product , client wants to add near search location base on zip code - that means if user enter zip code then user will receive nearest location within 5 or 10 mile.
    Like if we open subway or In-N-Out site for find out nearest store location
    Please let me know - How Can I do this task
    thanks
    amit

    I've never done such a project before. However, here are some ideas:
    * You need a list of every zip code in the country and its latitude and longitude (for the geographic center of each zip code).
    Search google for something like this:
    zip code latitude longitude
    Ideally, you should be able to find a free listing. If not, you should be able to purchase one cheaply.
    * Next, you need to create a list of stores, thier addresses, and their latitude and longitude.
    * Next, write a program that determines the distance between the list of zip code latitudes/longitudes and the latitutude/longitude of the store in question. From that list of distances, search for and get the ones within x miles of the store.
    Alternatively, you might want to see if there are any pre-existing services to do the above functionality for a small amount of money. I imagine mapquest might have such a service.

  • How to have ICWeb Identification screen on top left show premise zip code

    Previously in one of our training environments anytime a Business Partner and Premise were confirmed the top left hand screen in the ICWeb would show the BP first and last name as well as the premise and the premise zip code.  In our production environment the top left hand screen shows everything except for the premise zip code.
    Can somebody please explain how this field can pick up on the premise zip code whether it is done through SPRO or coding?
    Thanks
    Dave

    Hi David,
    This is proper coding issue. As you want  premise zip code to display in the contact information box. If I am not wrong. You can do it in Component CRMCMP_IC_FRAME. In the custom controller there is method SET_CALLER_DISPLAY_BPNAME where you need to get the premise zip code data and concatenate it to caller_display_name variable.
    Hope this will solve your issue.
    Thanks,
    Albert

  • CER 8.5 unable to put in Canada Zip code

    Hi,
    I've a client running CER 8.5 on VMWare. The System Locale is set to "United States".
    Client is adding an ALI for Canada but the ZIP code and ZIP code extension are not taking the valid canadian Zip codes which are Alpha Numberic.
    For example, one of the Valid Canadian Zip Code is: L6M2W1, when client tries to put it in, he gets the followoing message:
    "Please enter a valid numeric value for Zip Code".
    As per the CER 8.5 Administration guide, the Zip Code and Zip Code extension fields will take following values:
    Zip Code  ----- The postal zip code for the address.  ---- You are limited to 5 characters.
    Zip Code Extension --- The postal zip code "plus four" number.  ---- You are limited to 4 digits.
    The country Code and State are correctly set to CA/ON but still same error. Trying to update the existing ALIs are also throwing the same error.
    I am not sure what version they were running earlier, but he did say he never had this issue in previous CER version.
    Has someone else noticed it and is aware of any possible fix for it? Or client needs to change the Locale from "United States" to "Canada" to fix it?
    Thanks in advance,
    Kapil

    Thanks for your time replying.
    I figured it out and asked the client to ignore it.
    Not sure if he is going to like it, but what's Cisco's say on it?
    If I get it somewhere documented clearly that it's meant only for United States locations, it'll make things clear.
    Thanks,
    Kapil

  • How to find the user exit for the T-code 'RECN'

    Hi friends,
    I have a requirement as-
    In 'General Data with Fast Entry' tab of tcode 'RECN' there are 2 fields as contract conclusion date and contract end date.
    Now, the requirement is as if entered contract end date is less than contract conclusion date then we have to display a warning message as "contract end date cannot be less than contract conclusion date".
    So, how to find the right user exit to enter the code.
    Plz help me.I will surely reward points.
    Thanks,
    Rishi

    Hi Rishi,
    If User exits and BAdi's are not provided,  then  you will for Enhancement points.
    Procedure:
                     When you are in a particular transaction, Go to System--> status and you find the standard program of that particular screen. Go to SE38 and give that program name, display mode.
    After that you click on the spiral icon there onthe top. Then,
    You go to menu bar, Edit> Enhancement opitons> show implicit enhancement options.
    You will be shown the points where you need to write the code.
    For creating it you will go to Edit >  Enhancement opitons> Create.
    By this you will add some code in the standard programs.
    Reward points if it helps you.
    Cheers,
    Swamy Kunche

  • Need Menu Exit for T-Code ME32K in ECC

    Hello,
    I need Menu Exit for Transaction ME32K in ECC version, It would be helpful if any one could tell me,
    Deserving answer will be rewarded points
    Regards
    Rajesh

    hi
    use this program to search for the BADIS and enhancements
    & Report  ZPJA_PM002 (V2)                                            &
    & Text Elements:                                                     &
    & P_DEVC Show user-exits from development class                      &
    & P_LIMIT Limit submit program selection                             &
    & P_FUNC Show function modules                                       &
    & P_SUBM Show submit programs                                        &
    & S01    Selection data (TCode takes precedence  over program name)  &
    report  zpja_pm002
      no standard page heading
      line-size 158.
    *tables: enlfdir.     "Additional Attributes for Function Modules
    data: tabix      like sy-tabix,
          w_linnum   type i,
          w_off      type i,
          w_index    like sy-tabix,
          w_include  like trdir-name,
          w_prog     like trdir-name,
          w_incl     like trdir-name,
          w_area     like rs38l-area,
          w_level,
          w_str(50)  type c,
          w_funcname like tfdir-funcname.
    constants: c_fmod(40) type c value 'Function modules selected: ',
               c_subm(40) type c value 'Submit programs selected: ',
               c_col1(12) type c value 'Enhanmt Type',
               c_col2(40) type c value 'Enhancement',
               c_col3(30) type c value 'Program/Include',
               c_col4(20) type c value 'Enhancement Name',
               c_col5(40) type c value 'Enhancement Description'.
    Work Areas: ABAP Workbench
    data: begin of wa_d010inc.
    data: master type d010inc-master.
    data: end of wa_d010inc.
    data: begin of wa_tfdir.
    data: funcname type tfdir-funcname,
          pname    type tfdir-pname,
          include  type tfdir-include.
    data: end of wa_tfdir.
    data: begin of wa_tadir.
    data: devclass type tadir-devclass.
    data: end of wa_tadir.
    data: begin of wa_tstc.
    data: pgmna type tstc-pgmna.
    data: end of wa_tstc.
    data: begin of wa_tstcp.
    data: param type tstcp-param.
    data: end of wa_tstcp.
    data: begin of wa_enlfdir.
    data: area type enlfdir-area.
    data: end of wa_enlfdir.
    Work Areas: BADIs
    data: begin of wa_sxs_attr.
    data: exit_name type sxs_attr-exit_name.
    data: end of wa_sxs_attr.
    data: begin of wa_sxs_attrt.
    data: text type sxs_attrt-text.
    data: end of wa_sxs_attrt.
    Work Areas: Enhancements
    data: begin of wa_modsap.
    data: member type modsap-member.
    data: end of wa_modsap.
    data: begin of wa_modsapa.
    data: name type modsapa-name.
    data: end of wa_modsapa.
    data: begin of wa_modsapt.
    data: modtext type modsapt-modtext.
    data: end of wa_modsapt.
    Work Areas: Business Transaction Events
    data: begin of wa_tbe01t.
    data: text1 type tbe01t-text1.
    data: end of wa_tbe01t.
    data: begin of wa_tps01t.
    data: text1 type tps01t-text1.
    data: end of wa_tps01t.
    user-exits
    types: begin of t_userexit,
          type(12) type c,
          pname    like trdir-name,
          txt(300),
          level    type c,
          modname(30) type c,
          modtext(40) type c,
    end of t_userexit.
    data: i_userexit type standard table of t_userexit with header line.
    Function module developmnet classes
    types: begin of t_devclass,
          clas   like trdir-clas,
    end of t_devclass.
    data: i_devclass type standard table of t_devclass with header line.
    Submit programs
    types: begin of t_submit,
          pname     like trdir-name,
          level,
          done,
    end of t_submit.
    data: i_submit type standard table of t_submit with header line.
    Source code
    types: begin of t_sourcetab,                        "#EC * (SLIN lügt!)
            line(200),                                  "#EC * (SLIN lügt!)
          end of t_sourcetab.                           "#EC * (SLIN lügt!)
    data: sourcetab type standard table of t_sourcetab with header line.
    data c_overflow(30000) type c.
    Description of an ABAP/4 source analysis token
    data: i_stoken type standard table of stokex with header line.
    data wa_stoken like i_stoken.
    Description of an ABAP/4 source analysis statement
    data: i_sstmnt type standard table of sstmnt with header line."#EC
    keywords for searching ABAP code
    types: begin of t_keywords,
          word(30),
    end of t_keywords.
    data: keywords type standard table of t_keywords with header line.
    function modules within program
    types: begin of t_fmodule,
          name   like rs38l-name,
          pname  like trdir-name,
          pname2 like trdir-name,
          level,
          bapi,
          done,
    end of t_fmodule.
    data: i_fmodule type standard table of t_fmodule with header line.
    & Selection Options                                                  &
    selection-screen begin of block selscr1 with frame title text-s01.
    parameter: p_pname like trdir-name memory id rid,
               p_tcode like syst-tcode,
               p_limit(4) type n default 100,
               p_devc  like rihea-dy_ofn default ' ',
               p_func  like rihea-dy_ofn default ' ',
               p_subm  like rihea-dy_ofn default ' '.
    selection-screen end of block selscr1.
    & START-OF-SELECTION                                                 &
    start-of-selection.
      if p_pname is initial and p_tcode is initial.
        message e008(hrfpm).  "Make entry on the selection screen
        stop.
      endif.
    ensure P_LIMIT is not zero.
      if p_limit = 0.
        p_limit = 1.
      endif.
      perform data_select.
      perform get_submit_data.
      perform get_fm_data.
      perform get_additional_data.
      perform data_display.
    & Form DATA_SELECT                                                   &
    form data_select.
    data selection message to sap gui
      call function 'SAPGUI_PROGRESS_INDICATOR'
        destination 'SAPGUI'
        keeping logical unit of work
        exporting
          text                  = 'Get programs/includes'       "#EC NOTEXT
        exceptions
          system_failure
          communication_failure
        .                                                       "#EC *
    determine search words
      keywords-word = 'CALL'.
      append keywords.
      keywords-word = 'FORM'.
      append keywords.
      keywords-word = 'PERFORM'.
      append keywords.
      keywords-word = 'SUBMIT'.
      append keywords.
      keywords-word = 'INCLUDE'.
      append keywords.
      if not p_tcode is initial.
    get program name from TCode
        select single pgmna from tstc into wa_tstc-pgmna
                     where tcode eq p_tcode.
        if not wa_tstc-pgmna is initial.
          p_pname = wa_tstc-pgmna.
    TCode does not include program name, but does have refereve TCode
        else.
          select single param from tstcp into wa_tstcp-param
                       where tcode eq p_tcode.
          if sy-subrc = 0.
            check wa_tstcp-param(1)   = '/'.
            check wa_tstcp-param+1(1) = '*'.
            if wa_tstcp-param ca ' '.
            endif.
            w_off = sy-fdpos + 1.
            subtract 2 from sy-fdpos.
            if sy-fdpos gt 0.
              p_tcode = wa_tstcp-param+2(sy-fdpos).
            endif.
            select single pgmna from tstc into wa_tstc-pgmna
                   where tcode eq p_tcode.
            p_pname = wa_tstc-pgmna.
            if sy-subrc <> 0.
              message e110(/saptrx/asc) with 'No program found for: '
    p_tcode."#EC NOTEXT
              stop.
            endif.
          else.
            message e110(/saptrx/asc) with 'No program found for: ' p_tcode.
    "#EC NOTEXT
            stop.
          endif.
        endif.
      endif.
    Call customer-function aus Program coding
      read report p_pname into sourcetab.
      if sy-subrc > 0.
        message e017(enhancement) with p_pname raising no_program."#EC *
      endif.
      scan abap-source sourcetab tokens     into i_stoken
                                 statements into i_sstmnt
                                 keywords   from keywords
                                 overflow into c_overflow
                                 with includes.
                                 WITH ANALYSIS.
      if sy-subrc > 0. "keine/syntakt. falsche Ablauflog./Fehler im Skanner
        message e130(enhancement) raising syntax_error.         "#EC *
      endif.
    check I_STOKEN for entries
      clear w_linnum.
      describe table i_stoken lines w_linnum.
      if w_linnum gt 0.
        w_level = '0'.
        w_prog = ''.
        w_incl = ''.
        perform data_search tables i_stoken using w_level w_prog w_incl.
      endif.
    endform.                        "DATA_SELECT
    & Form GET_FM_DATA                                                   &
    form get_fm_data.
    data selection message to sap gui
      call function 'SAPGUI_PROGRESS_INDICATOR'
        destination 'SAPGUI'
        keeping logical unit of work
        exporting
          text                  = 'Get function module data'    "#EC NOTEXT
        exceptions
          system_failure
          communication_failure
        .                                                       "#EC *
    Function module data
      sort i_fmodule by name.
      delete adjacent duplicates from i_fmodule comparing name.
      loop at i_fmodule where done  ne 'X'.
        clear:   i_stoken, i_sstmnt, sourcetab, wa_tfdir, w_include .
        refresh: i_stoken, i_sstmnt, sourcetab.
        clear wa_tfdir.
        select single funcname pname include from tfdir into wa_tfdir
                                where funcname = i_fmodule-name.
        check sy-subrc = 0.
        call function 'FUNCTION_INCLUDE_SPLIT'
          exporting
            program = wa_tfdir-pname
          importing
            group   = w_area.
        concatenate 'L' w_area 'U' wa_tfdir-include into w_include.
        i_fmodule-pname  = w_include.
        i_fmodule-pname2 = wa_tfdir-pname.
        modify i_fmodule.
        read report i_fmodule-pname into sourcetab.
        if sy-subrc = 0.
          scan abap-source sourcetab tokens     into i_stoken
                                     statements into i_sstmnt
                                     keywords   from keywords
                                     with includes.
          if sy-subrc > 0.
            message e130(enhancement) raising syntax_error.
          endif.
    check i_stoken for entries
          clear w_linnum.
          describe table i_stoken lines w_linnum.
          if w_linnum gt 0.
            w_level = '1'.
            w_prog  = i_fmodule-pname2.
            w_incl =  i_fmodule-pname.
            perform data_search tables i_stoken using w_level w_prog w_incl.
          endif.
        endif.
      endloop.
      if p_devc = 'X'.
        loop at i_fmodule.
          clear: wa_tadir, wa_enlfdir.
          select single area from enlfdir into wa_enlfdir-area
                                where funcname = i_fmodule-name.
          check not wa_enlfdir-area is initial.
          select single devclass into wa_tadir-devclass
                          from tadir where pgmid    = 'R3TR'
                                       and object   = 'FUGR'
                                       and obj_name = wa_enlfdir-area.
          check not wa_tadir-devclass is initial.
          move wa_tadir-devclass to i_devclass-clas.
          append i_devclass.
          i_fmodule-done = 'X'.
          modify i_fmodule.
        endloop.
        sort i_devclass.
        delete adjacent duplicates from i_devclass.
      endif.
    endform.                        "GET_FM_DATA
    & Form GET_SUBMIT_DATA                                               &
    form get_submit_data.
    data selection message to sap gui
      call function 'SAPGUI_PROGRESS_INDICATOR'
        destination 'SAPGUI'
        keeping logical unit of work
        exporting
          text                  = 'Get submit data'             "#EC NOTEXT
        exceptions
          system_failure
          communication_failure
        .                                                       "#EC *
      sort i_submit.
      delete adjacent duplicates from i_submit comparing pname.
      w_level = '0'.
      loop at i_submit where done ne 'X'.
        clear:   i_stoken, i_sstmnt, sourcetab.
        refresh: i_stoken, i_sstmnt, sourcetab.
        read report i_submit-pname into sourcetab.
        if sy-subrc = 0.
          scan abap-source sourcetab tokens     into i_stoken
                                     statements into i_sstmnt
                                     keywords   from keywords
                                     with includes.
          if sy-subrc > 0.
           message e130(enhancement) raising syntax_error.
            continue.
          endif.
    check i_stoken for entries
          clear w_linnum.
          describe table i_stoken lines w_linnum.
          if w_linnum gt 0.
            w_prog  = i_submit-pname.
            w_incl = ''.
            perform data_search tables i_stoken using w_level w_prog w_incl.
          endif.
        endif.
    restrict number of submit program selected for processing
        describe table i_submit lines w_linnum.
        if w_linnum ge p_limit.
          w_level = '1'.
        endif.
        i_submit-done = 'X'.
        modify i_submit.
      endloop.
    endform.                       "GET_SUBMIT_DATA
    & Form DATA_SEARCH                                                   &
    form data_search tables p_stoken structure stoken
                            using p_level p_prog p_incl.
      loop at p_stoken.
        clear i_userexit.
        tabix = sy-tabix + 1.
        i_userexit-level = p_level.
        if i_userexit-level = '0'.
          if p_incl is initial.
            i_userexit-pname = p_pname.
          else.
            concatenate  p_pname '/' p_incl into i_userexit-pname.
          endif.
        else.
          if p_incl is initial.
            i_userexit-pname = p_prog.
          else.
            concatenate  p_prog '/' p_incl into i_userexit-pname.
          endif.
        endif.
    Include
        if p_stoken-str eq 'INCLUDE'.
          check p_level eq '0'.    " do not perform for function modules
    *(2nd pass)
          w_index = sy-tabix + 1.
          read table p_stoken index w_index into wa_stoken.
          check not wa_stoken-str cs 'STRUCTURE'.
          check not wa_stoken-str cs 'SYMBOL'.
          read table i_submit with key pname = wa_stoken-str.
          if sy-subrc <> 0.
            i_submit-pname = wa_stoken-str.
            i_submit-level = p_level.
            append i_submit.
          endif.
        endif.
    Enhancements
        if p_stoken-str eq 'CUSTOMER-FUNCTION'.
          clear w_funcname.
          read table p_stoken index tabix.
          translate p_stoken-str using ''' '.
          condense p_stoken-str.
          if p_prog is initial.
            concatenate 'EXIT' p_pname p_stoken-str into w_funcname
                         separated by '_'.
          else.
            concatenate 'EXIT' p_prog p_stoken-str into w_funcname
                   separated by '_'.
          endif.
          select single member from modsap into wa_modsap-member
                where member = w_funcname.
          if sy-subrc = 0.   " check for valid enhancement
            i_userexit-type = 'Enhancement'.
            i_userexit-txt  = w_funcname.
            append i_userexit.
          else.
            clear wa_d010inc.
            select single master into wa_d010inc-master
                  from d010inc
                     where include = p_prog.
            concatenate 'EXIT' wa_d010inc-master p_stoken-str into
    w_funcname
                   separated by '_'.
            i_userexit-type = 'Enhancement'.
            i_userexit-txt  = w_funcname.
          endif.
        endif.
    BADIs
        if p_stoken-str cs 'cl_exithandler='.
          w_index = sy-tabix + 4.
          read table p_stoken index w_index into wa_stoken.
          i_userexit-txt = wa_stoken-str.
          replace all occurrences of '''' in i_userexit-txt with space.
          i_userexit-type = 'BADI'.
          append i_userexit.
        endif.
    Business transaction events
        if p_stoken-str cs 'OPEN_FI_PERFORM'.
          i_userexit-type = 'BusTrEvent'.
          i_userexit-txt = p_stoken-str.
          replace all occurrences of '''' in i_userexit-txt with space.
          i_userexit-modname =  i_userexit-txt+16(8).
          case i_userexit-txt+25(1).
            when 'E'.
              clear wa_tbe01t.
              select single text1 into wa_tbe01t-text1 from tbe01t
                               where event = i_userexit-txt+16(8)
                                 and spras = sy-langu.
              if wa_tbe01t-text1 is initial.
                i_userexit-modtext = ''.            "#EC NOTEXT
              else.
                i_userexit-modtext = wa_tbe01t-text1.
              endif.
              i_userexit-modname+8 = '/P&S'.                    "#EC NOTEXT
            when 'P'.
              clear wa_tps01t.
              select single text1 into wa_tps01t-text1 from tps01t
                               where procs = i_userexit-txt+16(8)
                                 and spras = sy-langu.
              i_userexit-modtext = wa_tps01t-text1.
              i_userexit-modname+8 = '/Process'.
          endcase.
          append i_userexit.
        endif.
    Program exits
        if p_stoken-str cs 'USEREXIT_'.
          i_userexit-type = 'Program Exit'.
          i_userexit-txt = p_stoken-str.
          replace all occurrences of '''' in i_userexit-txt with space.
          append i_userexit.
        endif.
    Submit programs
        if p_stoken-str cs 'SUBMIT'.
          check p_level eq '0'.    " do not perform for function modules
    *(2nd pass)
          check not p_stoken-str cs '_'.   " ensure not SUBMIT_XXX
          w_index = sy-tabix + 1.
          read table p_stoken index w_index into wa_stoken.
          check not wa_stoken-str cs '_'.   " ensure not SUBMIT_XXX
          replace all occurrences of '''' in wa_stoken-str with space.
          read table i_submit with key pname = wa_stoken-str.
          if sy-subrc <> 0.
            i_submit-pname = wa_stoken-str.
            i_submit-level = p_level.
            append i_submit.
          endif.
        endif.
    Perform routines (which reference external programs)
        if p_stoken-str cs 'PERFORM'.
          check p_level eq '0'.    " do not perform for function modules
    *(2nd pass)
          w_index = sy-tabix + 1.
          read table p_stoken index w_index into wa_stoken.
          if not wa_stoken-ovfl is initial.
            w_off = wa_stoken-off1 + 10.
            w_str = c_overflow+w_off(30).
            find ')' in w_str match offset w_off.
            w_off = w_off + 1.
            wa_stoken-str = w_str(w_off).
          endif.
          check wa_stoken-str cs '('.
          w_off = 0.
          while sy-subrc  = 0.
            if wa_stoken-str+w_off(1) eq '('.
              replace section offset w_off length 1 of wa_stoken-str with ''
              replace all occurrences of ')' in wa_stoken-str with space.
              read table i_submit with key pname = wa_stoken-str.
              if sy-subrc <> 0.
                i_submit-pname = wa_stoken-str.
                append i_submit.
              endif.
              exit.
            else.
              replace section offset w_off length 1 of wa_stoken-str with ''
              shift wa_stoken-str left deleting leading space.
            endif.
          endwhile.
        endif.
    Function modules
        if p_stoken-str cs 'FUNCTION'.
          clear i_fmodule.
          check p_level eq '0'.    " do not perform for function modules
    *(2nd pass)
          w_index = sy-tabix + 1.
          read table p_stoken index w_index into wa_stoken.
         if wa_stoken-str cs 'WF_'.
         if wa_stoken-str cs 'IF_'.
           break-point.
         endif.
          if wa_stoken-str cs 'BAPI'.
            i_fmodule-bapi = 'X'.
          endif.
          replace first occurrence of '''' in wa_stoken-str with space.
          replace first occurrence of '''' in wa_stoken-str with space.
          if sy-subrc = 4.   " didn't find 2nd quote (ie name truncated)
            clear wa_tfdir.
            concatenate wa_stoken-str '%' into wa_stoken-str.
            select single funcname into wa_tfdir-funcname from tfdir
                         where funcname like wa_stoken-str.
            if sy-subrc = 0.
              i_fmodule-name = wa_tfdir-funcname.
            else.
              continue.
            endif.
          else.
            i_fmodule-name = wa_stoken-str.
          endif.
          i_fmodule-level = p_level.
          append i_fmodule.
        endif.
      endloop.
    endform.                        "DATA_SEARCH
    & Form GET_ADDITIONAL_DATA                                           &
    form get_additional_data.
    data selection message to sap gui
      call function 'SAPGUI_PROGRESS_INDICATOR'
        destination 'SAPGUI'
        keeping logical unit of work
        exporting
          text                  = 'Get additional data'         "#EC NOTEXT
        exceptions
          system_failure
          communication_failure
        .                                                       "#EC *
      loop at i_userexit.
    Enhancement data
        if  i_userexit-type cs 'Enh'.
          clear: wa_modsapa.
          select single name into wa_modsapa-name from modsap
                            where member = i_userexit-txt.
          check sy-subrc = 0.
          i_userexit-modname = wa_modsapa-name.
          clear wa_modsapt.
          select single modtext into wa_modsapt-modtext from modsapt
                            where name = wa_modsapa-name
                                         and sprsl = sy-langu.
          i_userexit-modtext = wa_modsapt-modtext.
        endif.
    BADI data
        if  i_userexit-type eq 'BADI'.
          clear wa_sxs_attr.
          select single exit_name into wa_sxs_attr-exit_name from sxs_attr
                                        where exit_name = i_userexit-txt.
          if sy-subrc = 0.
            i_userexit-modname = i_userexit-txt.
          else.
            i_userexit-modname = 'Dynamic call'.                "#EC NOTEXT
          endif.
          clear wa_sxs_attrt.
          select single text into wa_sxs_attrt-text from sxs_attrt
                                         where exit_name =
    wa_sxs_attr-exit_name
                                           and sprsl = sy-langu.
          i_userexit-modtext = wa_sxs_attrt-text.
        endif.
        modify i_userexit.
      endloop.
    get enhancements via program package
      clear wa_tadir.
      select single devclass into wa_tadir-devclass from tadir
                                 where pgmid    = 'R3TR'
                                   and object   = 'PROG'
                                   and obj_name = p_pname.
      if sy-subrc = 0.
        clear: wa_modsapa, wa_modsapt.
        select name from modsapa into wa_modsapa-name
                              where devclass = wa_tadir-devclass.
          select single modtext from modsapt into wa_modsapt-modtext
                              where name = wa_modsapa-name
                                and sprsl = sy-langu.
          read table i_userexit with key modname = wa_modsapa-name.
          if sy-subrc <> 0.
            i_userexit-modtext = wa_modsapt-modtext.
            i_userexit-type = 'Enhancement'.                    "#EC NOTEXT
            i_userexit-modname  = wa_modsapa-name.
            i_userexit-txt = 'Determined from program DevClass'."#EC NOTEXT
            i_userexit-pname = 'Unknown'.                       "#EC NOTEXT
            append i_userexit.
          endif.
        endselect.
      endif.
    endform.                        "GET_ADDITIONAL_DATA
    & Form DATA_DISPLAY                                                  &
    form data_display.
    data selection message to sap gui
      call function 'SAPGUI_PROGRESS_INDICATOR'
        destination 'SAPGUI'
        keeping logical unit of work
        exporting
          text                  = 'Prepare screen for display'  "#EC NOTEXT
        exceptions
          system_failure
          communication_failure
        .                                                       "#EC *
      sort i_userexit by type txt modname.
      delete adjacent duplicates from i_userexit comparing txt modname.
    format headings
      write: 'Enhancements from main program'.                  "#EC NOTEXT
      write: /.
      uline.
      format color col_heading.
      write: /    sy-vline,
             (12) c_col1,                    "Enhanmt Type
                  sy-vline,
             (40) c_col2,                    "Enhancement
                  sy-vline,
             (30) c_col3,                    "Program/Include
                  sy-vline,
             (20) c_col4,                    "Enhancement name
                  sy-vline,
             (40) c_col5,                    "Enhancement description
                  sy-vline.
      format reset.
      uline.
    format lines
      loop at i_userexit.
    set line colour
        case i_userexit-type.
          when 'Enhancement'.
            format color 3 intensified off.
          when 'BADI'.
            format color 4 intensified off.
          when 'BusTrEvent'.
            format color 5 intensified off.
          when 'Program Exit'.
            format color 6 intensified off.
          when others.
            format reset.
        endcase.
        write: / sy-vline,
                 i_userexit-type,
                 sy-vline,
                 i_userexit-txt(40),
                 sy-vline,
                 i_userexit-pname(30),
                 sy-vline,
                 i_userexit-modname(20),
                 sy-vline,
                 i_userexit-modtext(40),
                 sy-vline.
      endloop.
      format reset.
      uline.
    user-exits from development class of function modules
      if p_devc = 'X'.
        write: /.
        write: / 'User-exits from function module development class'."#EC
    *NOTEXT
        write: 157''.
        uline (90).
        write: 157''.
        loop at i_devclass.
          clear wa_modsapa.
          select name from modsapa into wa_modsapa
                       where devclass = i_devclass-clas.
         select single name modtext into corresponding fields of wa_modsapt
                                       from modsapt
                                         where name  = wa_modsapa-name
                                           and sprsl = sy-langu.
            format color 3 intensified off.
            write: / sy-vline,
                     (12) 'Enhancement',
                     sy-vline,
                    wa_modsapa-name,
                    sy-vline,
                    wa_modsapt-modtext,
                    sy-vline.
          endselect.
        endloop.
        uline (90).
        format reset.
      endif.
      describe table i_fmodule lines w_linnum.
      write: / c_fmod , at 35 w_linnum.                         "#EC NOTEXT
      write: 157''.
      if p_func = 'X'.
    display fuction modules used in program
        uline (38).
        write: 157''.
        loop at i_fmodule.
          write: sy-vline,
                 i_fmodule-name,
                 sy-vline,
                 i_fmodule-bapi,
                 sy-vline.
          write: 157''.
        endloop.
        uline (38).
      endif.
      describe table i_submit lines w_linnum.
      write: / c_subm , at 35 w_linnum.                         "#EC NOTEXT
      write: 157''.
      if p_subm = 'X'.
    display submit programs used in program
        uline (44).
        write: 157''.
        loop at i_submit.
          write: sy-vline,
                 i_submit-pname,
                 sy-vline.
          write: 157''.
        endloop.
        uline (44).
      endif.
    issue message with number of user-exits displayed
      describe table i_userexit lines w_linnum.
      message s697(56) with w_linnum.
    endform.                        "DATA_DISPLAY
    reward points if it helps
    gunjan

  • Please help, finding all zip codes within a given radius.

    I have a table which contains zip, city, state, latdec, longdec, latrad, longrad.
    From search screen, user want's to find all zip code's, within
    10 mile radius of his zip code.
    I came up with following sql but it is not correct:
    First, find his latdec, longdec from his zipcode.
    Then add radius to those values and do select as follows:
    select zip,
    latdec, longdec,
    city, state, latrad, longrad
    from zip_coord
    where latdec >= (latdec - 10)
    and latdec <= (latdec + 10)
    and longdec >= (longdec - 10)and longdec <= (longdec + 10).
    I think i need to include radians too, but i'm not able to come up with logical formula.
    I would appreciate any help with this topic.
    Thanks in advance

    I am not sure I understand the gerography concept, but I think the query should be like this:
    select zip, latdec, longdec,city, state, latrad, longrad
    from zip_coord
    where latdec between( select latdec from zip_record where zip='userinput', select latdec+10 from zip_record where zip='userinput')
    and longdec between( select longdec from zip_record where zip='userinput', select longdec+10 from zip_record where zip='userinput')
    and latrad between( select latrad from zip_record where zip='userinput', select latrad+10 from zip_record where zip='userinput')
    and longrad between( select longrad from zip_record where zip='userinput', select longrad+10 from zip_record where zip='userinput')
    Hope, it can help.
    Aiping

  • Sql help please with, finding all zip codes within a given radius.

    I have a table which contains zip, city, state, latdec, longdec, latrad, longrad.
    From search screen, if user want, zip code's within 10 mile radius of his zip code, what is the sql. I came up with following sql but it is not correct:
    first, find his latdec long dec from his zipcode. Then add radius to those values and do select as follows:
    select zip,
    latdec, longdec,
    city, state, latrad, longrad
    from zip_coord
    where latdec >= (latdec - 10)
    and latdec <= (latdec + 10)
    and longdec >= (longdec - 10)and longdec <= (longdec + 10).
    I think i need to include radians too, but i'm not able to come up with logical formula.
    I would appreciate any help with this topic.
    Thanks in advance

    gautam ,
    u probably need to use oracle spatial option and store geoCodes for each address as a column in the address table . then doing this will be easy

  • I need help drawing a state map that highlights demographic data by zip code and county

    I'm trying to draw a map of Florida that highlights some data I've collected.  I need to be able to show distinctions between/among counties and zip codes.  The "make a map of geographic data" video didn't really help me, as it gave no instructions on how to find the blank map in the first place.
    Any help, please?  Thanks
    Make a map of geographic data | Adobe for Academics | Adobe TV

    google or equivalent. how did illustrator give you that impression? it's for creating content, generally, not a clipart library.
    edit: there are several here with county boundaries that you could probably convert to your needs:
    Category:SVG maps of Florida - Wikimedia Commons

  • Having problem buying online.need your help since it's my first time here.apple is asking for my billing address but when i enter my address here in qatar,it's saying i should enter a valid zip code within the u.s.does it mean i can't buy online

    having problem buying online.need your help since it's my first time here.apple is asking for my billing address but when i enter my address here in qatar,it's saying i should enter a valid zip code within the u.s.does it mean i can't buy online even if it wil be shipped within u.s. only?

    To buy in for delivery in Qatar, you should be starting from the Apple Qatar site:
    http://www.apple.com/qa/
    Do you have an Apple-ID? if you do, then you should not have to enter your Address again, and may be able to sidestep the US Zip Code issue.

  • Find active user exit for a transaction code

    Hi All,
    Please help to find the active user exit for a transaction code.
    for Ex. below is the list of user exits for package VA ( for creation of sales order and changing sales order). Let me know which user exit is active and which is not active.
      Exit name    Short text
      SDTRM001  Reschedule schedule lines without a new ATP check
      V45A0001  Determine alternative materials for product selection
      V45A0002  Predefine sold-to party in sales document
      V45A0003  Collector for customer function modulpool MV45A
      V45A0004  Copy packing proposal
      V45E0001  Update the purchase order from the sales order
      V45E0002  Data transfer in procurement elements (PRreq., assembly)
      V45L0001  SD component supplier processing (customer enhancements)
      V45P0001  SD customer function for cross-company code sales
      V45S0001  Update sales document from configuration
      V45S0003  MRP-relevance for incomplete configuration
      V45S0004  Effectivity type in sales order
      V45W0001  SD Service Management: Forward Contract Data to Item
      V46H0001  SD Customer functions for resource-related billing
      V60F0001  SD Billing plan (customer enhancement) diff. to billing plan
    Thanks & Regards,
    Sabu

    Goto TADIR table give program id as R3TR ,Objec type as CMOD and execute.
    You will get all active exits in system.
    Exits related to SD may be in ZSD package.

Maybe you are looking for