How can I define global variable in user exit whic I can use anywhere.

Hi all,
How can I define global variable( Table ) which I can use when it come back to same user exit where I defined and stored some data.
What I mean is I want to define 1 global table.
In user exit when it comes I store some information. and again when it will come I will have that stored information so I can use it.
Thanks a lot in advance.

You can use EXPORT  TO MEMORY ID and IMPORT FROM MEMORY ID Statement for this.
EXPORT T_ITAB FROM T_ITAB TO MEMORY ID 'ABC'.
IMPORT T_ITAB TO T_ITAB FROM MEMORY ID 'ABC.'

Similar Messages

  • How to access the global data in user exit.

    Hi All,
    How to access the global data in user exit.
    the question is that when we were writing a code in the FM. i need to read data from the standard program like newly created documen and this document number need to be accessed in my program.
    this document number is not imported to the FM i needed to access for frther proceed.
    Thanks in advance.

    Hi,
    See the below PDF file by Jeff Goldstein. There you can find all the details about accessing data outside of the exit.
    [SAP User Exits and the People Who Love Them|https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/208811b0-00b2-2910-c5ac-dd2c7c50c8e8]
    This will help you to solve your problem.
    Regards
    Karthik D
    Edited by: Karthik D on Dec 2, 2008 4:18 PM

  • How can we find all the available  user-exits in sap without using SMOD?.

    How can we find all the available  user-exits in sap without using SMOD?.

    Hi,
    Please check this links for user exits list.
    http://www.planetsap.com/Userexit_List.htm
    http://www.easymarketplace.de/userexit.php
    http://www.sap-img.com/ab038.htm
    Regards,
    Ferry Lianto

  • How to find if 1000 variables have user exit or not

    Hi could you please let me know  any table
    to find if a list of variables In bex have a user exit or not .
    actually i have 7000 variables and want to document if these variables have a user exit or not for Reporting Documentation
    Wuld really appreciate your help
    Thanks and regards
    Novino

    Hi,
    See following tables related to Rpeorts, so check in that tables to find the Variables and properties
    Use RSZGLOBV table and there give OBJVERS = A and VPROCTP = 3 or 4 then execute it and se eth variables, all that are SAP/Customer Exit varaibles.
    RSZELTDIR Directory of the reporting component elements
    RSZELTTXT Texts of reporting component elements
    RSZELTXREF Directory of query element references
    RSRREPDIR Directory of all reports (Query GENUNIID)
    RSZCOMPDIR Directory of reporting components
    RSZRANGE Selection specification for an element
    RSZSELECT Selection properties of an element
    RSZELTDIR Directory of the reporting component elements
    RSZCOMPIC Assignment reuseable component <-> InfoCube
    RSZELTPRIO Priorities with element collisions
    RSZELTPROP Element properties (settings)
    RSZELTATTR Attribute selection per dimension element
    RSZCALC Definition of a formula element
    RSZCEL Query Designer: Directory of Cells
    RSZGLOBV Global Variables in Reporting
    Thanks
    Reddy

  • Is it good practice to define text elements in User exits & there by using?

    Hi Experts,
    Simple doubt that, am wrting code in a User Exit. So, here my code works only, if the DOC TYPE = 'XXX'.
    So, instead of using hard coding as 'XXX', I wuld like to use a text element, like
    if DOC TYPE = text-xxx.
    my logic.
    endif.
    and creating the same text element.
    so, let me know that,
    Is it safe/recommended to use text-element in exits?
    Is it good practice to define text elements in User exits?
    thanq

    u can also use SET ID's if u dont want to hardcode like that in ur program.
    if u use SET ids , no need of transport request in case of change in the DOC types , directly u can change values in that set it , its like a master id.
    sytax will be like this
    doc_type in g_doc_type(this is set id ).
    for creation of set ids see tcode GS01.
    regards
    Prabhu

  • How can I access global variables in a loaded Applescript?

    How can I access global variables in a loaded script, in Xcode, ApplescriptObjC? Basically, I have a global variable defined in my parent script using "property", and I need to modify objects connected to those variables inside of a loaded script.
    Example:
    Parent script:
    script AppDelegate
    property myTextField : missing value
    //linked to a text field object
    tell myScript to myAwesomeHandler_()
    end script
    Loaded script:
    on myAwesomeHandler_()
    myTextField's setStringValue_("The new Xcode is so glitchy ugh")
    //changes value of linked text field of parent script
    end myAwesomeHandler_
    The problem is, the variable is undefined in the Loaded script, and I need it to have the same value as the parent script, and I don't want to pass the variable through the Handler. Any ideas?

    I think want you are looking to do will need to be done in two steps. Because myTextField needs to be a property for the ObjectiveC part of the code you cannot turn it into a global.
    However if you make a temporary variable global assign the string to it in the handler then set myTextField off of it.
    global myTextFieldGlobal
    script AppDelegate 
    property myTextField : missing value 
    //linked to a text field object 
    tell myScript to myAwesomeHandler_() 
    myTextField's setStringValue_(myTextFieldGlobal)
    end script 
    on myAwesomeHandler_() 
    set myTextFieldGlobal to "The new Xcode is so glitchy ugh"
    //changes value of linked text field of parent script 
    end myAwesomeHandler_ 
    I know you stated you did not want the handler to return a value but I have to ask why? Global's, imo, are not a good idea and really should be used as a last resort.
    One other possibility is to pass a reference to the property to the handler. Not sure if that works in AS of if that would satisfy our requirement of not passing the variable through the handler
    <edit>
    Another though have you tried to define the property outside the script?  That is
    property myTextField : missing value
    script AppDelegate
    Not sure if that will work.
    You might also want to have a look at Scope of Properties and Variables Declared in a Script Object

  • Define Global Variable in XSLt

    H,
    Please let me know how to define Global Variable in XSLT.
    I have define a variable under for-each and i want to use that variable after for-each.
    Please suggest on the same.
    Thanks,
    Pradeep

    Hi Pradeep,
    IN XSL design, right click on target node and then select --> Add Variable. Give the name you desire to that variable and click OK. You can use that variable anywhere in that particular XSLT. In the source xsl you will see entry like this after adding your variable
    "<xsl:variable name="your variable name">value you want to give</xsl:variable>".
    Hope this helps.
    Regards,
    Karan

  • Loading defining global variables?

    Hello all!
    I have a project that is an online presentation, which I (being no pro in codeing) create in Edge and Muse. I create the animation in Edge, publish it as OAM and place it into the muse site/page. Master looks fine and I am happy with it.
    My problem, that I have to solve, is that it has to be translated into 44 Languages and kept updated regularly, which is near to impossible without using external data source.
    I thought to create an XML file for each language and use it for text and maybe Image content. I can use an xml file for a specific animation, but at my current knowledge level i!Il have to define the variables and the source of content for each and every animation/object.
    What I would like to see is that if you land on the Index page, you can choose the preferred language, and all the content appeares in the given language. For that (my best guess) I'll have to define global variables, which do not lose their value i.e.: which is my preferred language.
    How do I do that? Had anyone a similar issue? Also, how do I use external data in Muse?
    Any help would be appreciated!
    Greetz
    ND

    Here it is :
    In the Stage > document.compositionReady event handler, we define a JavaScript object LANG containing
    • a property flag that is the state of the displayed flag (in the example file, symbol drapeau, french for flag) ;
    • a function switchLang executed each time the flag is clicked, to refresh the content of
    - the three titles (b1A_tit, b1B_tit, b1C_tit) by  assigning hard-coded values,
    - the three texts (b1A_txt, b1B_txt, b1C_txt) by loading HTML snippets files in a text folder.
    LANG =
      flag: 'NL',
      switchLang: function()
        sym.getSymbol('bandeauH').getSymbol('drapeau').stop( LANG.flag);
        var symBloc1A = sym.getSymbol("bloc1A");
        var symBloc1B = sym.getSymbol("bloc1B");
        var symBloc1C = sym.getSymbol("bloc1C");
        switch (LANG.flag)
          case 'NL':
            symBloc1A.$('b1A_tit').html("Montagne");
            symBloc1A.$('b1A_txt').load('text/b1A_FR.html');
            symBloc1B.$('b1B_tit').text("Peinture");
            symBloc1B.$('b1B_txt').load('text/b1B_FR.html');
            symBloc1C.$('b1C_tit').text("Maison d’hôtes");
            symBloc1C.$('b1C_txt').load('text/b1C_FR.html');
            LANG.flag = 'FR';
            break;
          case 'FR':
            symBloc1A.$("b1A_tit").text("Montagne");
            symBloc1A.$('b1A_txt').load('text/b1A_NL.html');
            symBloc1B.$("b1B_tit").text("Schilderen");
            symBloc1B.$('b1B_txt').load('text/b1B_NL.html');
            symBloc1C.$("b1C_tit").text("Bed & Breakfast");
            symBloc1C.$('b1C_txt').load('text/b1C_NL.html');
            LANG.flag = 'NL';
            break;
    LANG.switchLang();
    The drapeau > click event handler is a single call to LANG.switchLang();
    Download the example file here : https://app.box.com/s/f8boa2oswnowyl3ehb2o
    Gil

  • How do I set global variables for use by ALL form1.#subform[0] items?

    Hi All,
    I know how to code javascript but am new to Adobe LiveCycle.  When I open script editor, I have the following code (all code is in un-bolded):
    ----- form1.#subform[0]::initialize: - (FormCalc, client) ------------------------------------------
    // BEGIN: SET GLOBAL PRICES //
    var Cityscope_Sydney_CostUser1 = 60.39;
    var Cityscope_Sydney_CostUsers2to5 = 3.02;
    var Cityscope_Sydney_CostUsers6to20 = 1.21;
    var Cityscope_Sydney_CostHardCopyWithOnline = 14.59;
    var Cityscope_Sydney_CostHardCopyWithoutOnline = 54.67;
    var Cityscope_Sydney_CostHardCopyAdditional = 14.59;
    var Cityscope_NorthSydney_CostUser1 = 48.40;
    var Cityscope_NorthSydney_CostUsers2to5 = 2.42;
    var Cityscope_NorthSydney_CostUsers6to20 = 0.97;
    var Cityscope_NorthSydney_CostHardCopyWithOnline = 14.59;
    var Cityscope_NorthSydney_CostHardCopyWithoutOnline = 43.54;
    var Cityscope_NorthSydney_CostHardCopyAdditional = 14.59;
    // END: SET GLOBAL PRICES //
    ----- form1.#subform[0]::enter: - (FormCalc, client) -----------------------------------------------
    ----- form1.#subform[0]::exit: - (FormCalc, client) ------------------------------------------------
    ----- form1.#subform[0]::calculate: - (FormCalc, client) -------------------------------------------
    ----- form1.#subform[0]::validate: - (FormCalc, client) --------------------------------------------
    ----- form1.#subform[0]::preSave - (FormCalc, client) ----------------------------------------------
    <<======= etc etc etc =======>>
    ----- form1.#subform[0].Item1Cost::initialize: - (JavaScript, client) ------------------------------
    ----- form1.#subform[0].Item1Cost::enter: - (FormCalc, client) -------------------------------------
    ----- form1.#subform[0].Item1Cost::exit: - (FormCalc, client) --------------------------------------
    ----- form1.#subform[0].Item1Cost::calculate: - (JavaScript, client) -------------------------------
    //Store form values in user-friendly names.
    var AreaSelected = Item1Area.rawValue;
    var NumberOfUsersSelected = Item1Users.rawValue;
    //Declare other vars.
    var Users1Calculation;
    var Users2to5Calculation;
    var Users6to20Calculation;
    //Calculate individual User Cost "components" based on number of users selected for the area.
    switch(true)
    case (NumberOfUsersSelected < 2):
      Users1Calculation = NumberOfUsersSelected * Cityscope_Sydney_CostUser1;
      Users2to5Calculation = 0.00;
      Users6to20Calculation = 0.00;
      break;
    case (NumberOfUsersSelected > 1 && NumberOfUsersSelected < 6):
      Users1Calculation = Cityscope_Sydney_CostUser1;
      Users2to5Calculation = (NumberOfUsersSelected - 1) * Cityscope_Sydney_CostUsers2to5;
      Users6to20Calculation = 0.00;
      break;
    case (NumberOfUsersSelected > 5):
      Users1Calculation = Cityscope_Sydney_CostUser1;
      Users2to5Calculation = 4 * Cityscope_Sydney_CostUsers2to5;
      Users6to20Calculation = (NumberOfUsersSelected - 5) * Cityscope_Sydney_CostUsers6to20;
      break;
    default:
      alert("BROKEN: Calculate individual User Cost components based on number of users selected for the area.");
    //apply total cost for this item
    Item1Cost.rawValue = Users1Calculation + Users2to5Calculation + Users6to20Calculation;
    ----- form1.#subform[0].Item1Cost::validate: - (FormCalc, client) ----------------------------------
    ----- form1.#subform[0].Item1Cost::mouseEnter: - (FormCalc, client) --------------------------------
    ----- form1.#subform[0].Item1Cost::mouseExit: - (FormCalc, client) ---------------------------------
    ----- form1.#subform[0].Item1Cost::change: - (FormCalc, client) ------------------------------------
    ----- form1.#subform[0].Item1Cost::full: - (FormCalc, client) --------------------------------------
    ----- form1.#subform[0].Item1Cost::mouseUp: - (FormCalc, client) -----------------------------------
    ----- form1.#subform[0].Item1Cost::mouseDown: - (FormCalc, client) ---------------------------------
    ----- form1.#subform[0].Item1Cost::click: - (FormCalc, client) -------------------------------------
    ----- form1.#subform[0].Item1Cost::preSave - (FormCalc, client) ------------------------------------
    ----- form1.#subform[0].Item1Cost::postSave - (FormCalc, client) -----------------------------------
    ----- form1.#subform[0].Item1Cost::prePrint - (FormCalc, client) -----------------------------------
    ----- form1.#subform[0].Item1Cost::postPrint - (FormCalc, client) ----------------------------------
    ----- form1.#subform[0].Item1Cost::preSubmit:form - (FormCalc, client) -----------------------------
    ----- form1.#subform[0].Item1Cost::docReady - (FormCalc, client) -----------------------------------
    ----- form1.#subform[0].Item1Cost::docClose - (FormCalc, client) -----------------------------------
    ----- form1.#subform[0].Item1Cost::ready:form - (FormCalc, client) ---------------------------------
    ----- form1.#subform[0].Item1Cost::ready:layout - (FormCalc, client) -------------------------------
    ----- form1.#subform[0].Item1Users::initialize: - (FormCalc, client) -------------------------------
    ----- form1.#subform[0].Item1Users::enter: - (FormCalc, client) ------------------------------------
    ----- form1.#subform[0].Item1Users::exit: - (FormCalc, client) -------------------------------------
    ----- form1.#subform[0].Item1Users::calculate: - (FormCalc, client) --------------------------------
    ----- form1.#subform[0].Item1Users::validate: - (FormCalc, client) ---------------------------------
    ----- form1.#subform[0].Item1Users::mouseEnter: - (FormCalc, client) -------------------------------
    ----- form1.#subform[0].Item1Users::mouseExit: - (FormCalc, client) --------------------------------
    ----- form1.#subform[0].Item1Users::change: - (FormCalc, client) -----------------------------------
    ----- form1.#subform[0].Item1Users::full: - (FormCalc, client) -------------------------------------
    ----- form1.#subform[0].Item1Users::mouseUp: - (FormCalc, client) ----------------------------------
    ----- form1.#subform[0].Item1Users::mouseDown: - (FormCalc, client) --------------------------------
    ----- form1.#subform[0].Item1Users::click: - (FormCalc, client) ------------------------------------
    ----- form1.#subform[0].Item1Users::preSave - (FormCalc, client) -----------------------------------
    ----- form1.#subform[0].Item1Users::postSave - (FormCalc, client) ----------------------------------
    ----- form1.#subform[0].Item1Users::prePrint - (FormCalc, client) ----------------------------------
    ----- form1.#subform[0].Item1Users::postPrint - (FormCalc, client) ---------------------------------
    ----- form1.#subform[0].Item1Users::preSubmit:form - (FormCalc, client) ----------------------------
    ----- form1.#subform[0].Item1Users::docReady - (FormCalc, client) ----------------------------------
    ----- form1.#subform[0].Item1Users::docClose - (FormCalc, client) ----------------------------------
    ----- form1.#subform[0].Item1Users::ready:form - (FormCalc, client) --------------------------------
    ----- form1.#subform[0].Item1Users::ready:layout - (FormCalc, client) ------------------------------
    ...and so on and so forth....
    In short, I want the code within:
    ----- form1.#subform[0].Item1Cost::calculate: - (JavaScript, client) -------------------------------
    ...to be able to access the variables I have created in:
    ----- form1.#subform[0]::initialize: - (FormCalc, client) ------------------------------------------
    (I have assumed that this is where I would store Global variables)
    At this stage, the global variables cannot be accessed with the configuration above.  The only was I can get this to work is to cut and paste the global vairables into each form1.#subform[0] item, which of course defeats the purpose of global variables!  I plan to have many more items so would not want to duplicate the global variables for all of them!
    Can somebody show me how to do this?
    Any help is very much appreciated!
    Thanks
    Stanbridge
    Message was edited by: stanbridgej - colors and or fonts won't save.  Have bolded my question to make code (non-bolded) easier to read (I hope).

    Hi MorisTM,
    Thanks for the reply!
    Yes, I saw that option (I should have mentioned I already knew about it), but was wondering if there is a way I can do this via code.
    There are two reason I want to be able to do it via code (only one of which may be valid):
    1) I can automatically generate my pricing code form another inhouse app.
    2) I am hoping that later on once I get this working I will be able take it a step further and get the data directly from a MySQL database!
    Cheers though!
    Any other suggestions?
    Regards,
    Stanbridge

  • How can i display warning messages in user exit EXIT_SAPLMGMU_001 (MM02)

    Hi all,
    while modifying the material master using MM02, i have added new conditions to display messages in user exit EXIT_SPALMGMU_001.
    But using this user exit i am not able to display warning messages.
    Can you please help me with this?
    Sample code which i have included in exit :
    SELECT SINGLE mstav FROM mara
    INTO w_mstav
    WHERE matnr = wmara-matnr.
    IF wmara-mstav NE w_mstav.
    IF wmara-mstdv NE sy-datum.
    wmara-mstdv = sy-datum.
    MESSAGE w177(z03_mm) WITH text-s04 text-s21.
    ENDIF.
    ENDIF.
    Thank you all in advance.

    As written in the SAP documentation of the Enhancement , you can only raise error message using a
    MESSAGE .. RAISING APPLICATION_ERROR.
    You could manage the "warning" yourself, sending an error first time and keeping a trace of the check in some STATICS variable, and not raising the error again if data input remains unchanged between two call of the include.
    <i>----
    EXIT_SAPLMGMU_001
    Where Is the Customer Exit - EXIT_SAPLMGMU_001 called?
    The customer exit is in function module MATERIAL_UPDATE_ALL. The
    function module checks the data for errors (logical relationships,
    foreign keys, fixed domain values, and so on) when the material master
    is updated.
    Use
    o New fields
    You can make checks possible for new fields of your own. These
    checks must be identical to the checks that you carry out for your
    new fields in online maintenance.
    o Existing fields
    For existing fields, you can extend and intensify the checks.
    You can also change data for descriptions and general material data
    (MARA). For example, the descriptions can be generated from attributes
    of the material.
    Limitations
    You cannot bypass existing checks.
    Interface to Application
    The respective data of the current logical transaction is contained in
    the structures, for example, in structure WMARA for MARA. Nonrelevant
    structures are transferred with their initial values.
    General material data that can be changed (CMARA) has the structure
    MARU. This MARA view contains fewer internal fields than MARA itself. If
    WMARA is filled, CMARA is also filled when accessed.
    The customer exit contains the exception APPLICATION_ERROR for your
    self-defined error situations.
    Using the language element MESSAGE .. RAISING APPLICATION_ERROR, you can
    terminate the current (logical) transaction and display your message in
    the log. </i>
    Regards

  • How can we find the list of user exits for a transaction

    hi all
    iam new in user exits please send the basic details
    how can we find the list of user exit for a perticular transaction and how can we determine that a particulr user exit is used for a field
    regards
    jagadish

    hi,
    check the below links for userexits
    http://help.sap.com/saphelp_46c/helpdata/en/64/72369adc56d11195100060b03c6b76/frameset.htm
    FAQ's
    http://http://www.sap-img.com/abap/a-short-tutorial-on-user-exits.htm
    http://www.ficoexpertonline.com/downloads/User%20ExitsWPedit.doc
    http://www.easymarketplace.de/userexit.php
    http://wiki.ittoolbox.com/index.php/HOWTO:Implement_a_screen_exit_to_a_standard_SAP_transaction
    1. what is the defference between enhancement and user-exits?
    http://www.sap-img.com/abap/difference-between-badi-and-user-exits.htm
    Re: difference between user exits & customer exits
    Some Questions ! Plz help...
    http://searchsap.techtarget.com/expert/KnowledgebaseAnswer/0,289625,sid21_gci1190924_tax299358,00.html?bucket=ETA
    2. Difference between CMOD and SMOD?
    http://www.sap-img.com/abap/what-is-the-difference-between-smod-and-cmod.htm
    http://www.sap-img.com/abap.htm
    http://sap.ittoolbox.com/groups/technical-functional/sap-r3-dev/diff-between-cmod-and-smod-236095
    http://sap.ittoolbox.com/groups/technical-functional/sap-r3-dev/diff-between-cmod-and-smod-236107
    check these links..
    http://www.sapgenie.com/abap/tips_and_tricks.htm
    http://www.sap-img.com/abap/field-exits-smod-cmod-questions-and-answers.htm
    http://www.sap-img.com/abap/what-is-user-exits.htm
    passing selet-option variable to subrouine...
    Finding the user-exits of a SAP transaction code
    Finding the user-exits of a SAP transaction code
    Enter the transaction code in which you are looking for the user-exit
    and it will list you the list of user-exits in the transaction code.
    Also a drill down is possible which will help you to branch to SMOD.
    Written by : SAP Basis, ABAP Programming and Other IMG Stuff
                 http://www.sap-img.com/*
    report zuserexit no standard page heading.
    tables : tstc, tadir, modsapt, modact, trdir, tfdir, enlfdir.
             tables : tstct.
    data : jtab like tadir occurs 0 with header line.
    data : field1(30).
    data : v_devclass like tadir-devclass.
    parameters : p_tcode like tstc-tcode obligatory.
    select single * from tstc where tcode eq p_tcode.
    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.
             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 eq enlfdir-area.
                move : tadir-devclass to v_devclass.
              endif.
           endif.
           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.
                        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.
            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.
    at line-selection.
       get cursor field field1.
       check field1(4) eq 'JTAB'.
       set parameter id 'MON' field sy-lisel+1(10).
       call transaction 'SMOD' and skip first   screen.
    *---End of Program
    if u want to find the function exit
    then check the below code
    REPORT ZV_FIND_EXIT NO STANDARD PAGE HEADING.
    TABLES : TSTC, TADIR, MODSAPT, MODACT, TRDIR, TFDIR, ENLFDIR.
    TABLES : TSTCT.
    DATA : JTAB LIKE TADIR OCCURS 0 WITH HEADER LINE.
    DATA : FIELD1(30).
    DATA : V_DEVCLASS LIKE TADIR-DEVCLASS.
    PARAMETERS : P_TCODE LIKE TSTC-TCODE OBLIGATORY.
    SELECT SINGLE * FROM TSTC WHERE TCODE EQ P_TCODE.
    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.
    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 EQ ENLFDIR-AREA.
    MOVE : TADIR-DEVCLASS TO V_DEVCLASS.
    ENDIF.
    ENDIF.
    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.
    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.
    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.
    AT LINE-SELECTION.
    GET CURSOR FIELD FIELD1.
    CHECK FIELD1(4) EQ 'JTAB'.
    SET PARAMETER ID 'MON' FIELD SY-LISEL+1(10).
    CALL TRANSACTION 'SMOD' AND SKIP FIRST SCREEN.
    or
    1. in se11, goto table MODSAP
    View table contents
    2. in Type field, enter 'E' (for function exit)
    3. For that tcode, u should know the program name.
    eg. SAPLLMOB
    4. then type SAPLLMOB and execute
    or
    REPORT z34331_user_exit .
    TABLES : 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
    DATA : jtab LIKE tadir OCCURS 0 WITH HEADER LINE.
    DATA : field1(30).
    DATA : v_devclass LIKE tadir-devclass.
    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-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.
    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 = enlfdir-area.
    MOVE : tadir-devclass TO v_devclass.
    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.
    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.
    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.
    Take the user to SMOD for the Exit that was selected.
    AT LINE-SELECTION.
    GET CURSOR FIELD field1.
    CHECK field1(4) EQ 'JTAB'.
    SET PARAMETER ID 'MON' FIELD sy-lisel+1(10).
    CALL TRANSACTION 'SMOD' AND SKIP FIRST SCREEN.
    Regards,
    Naveen

  • How to create a global variable in forms 6i

    How to create a global variable in forms 6i

    :GLOBAL.my_var := 15; Well, this statement is not correct! Global variables
    stores a character string of up to 255 characters in
    length. Thus, valid statement for Khurram example
    is:
    :GLOBAL.my_var := TO_CHAR(15);
    or
    :GLOBAL.my_var := '15';
    But numeric values are implicitly converted by oracle so there's nothing in fact wrong with the statement...
    :GLOBAL.my_var := 15;
    ;)

  • How can we identify what are all user exits are there for sales orders,deli

    Dear All,
    How can we identify what are all user exits are there for sales orders,deliverys and invoices
    thanks
    nitchel v

    Hi Nitchel
    There are many ways to find out the user exits..
    For example for VA01.
    Goto Transaction ie VA01:
    goto System-- Status
    doubleclick on the program name ie SAPMV45A
    SE38 -> Enter the program name and in the program( SAPMV45A) goto -- attributes
    get the package name from here ie VA
    note the package(VA) and get back to main screen
    goto SMOD tcode  and click on find button in the package spec giv the package name ie VA and execute it
    you will find list of exits available
    check out the exit that suits ur requirement
    goto cmod and create a new project and implement in that user exit.
    You will get the following exits in SMOD..
    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
    For Delivery you will get .. here the package name will be VL.
    V02V0001  Sales area determination for stock transport order
    V02V0002  User exit for storage location determination
    V02V0003  User exit for gate + matl staging area determination (h
    V02V0004  User Exit for Staging Area Determination (Item)
    V50PSTAT  Delivery: Item Status Calculation
    V50Q0001  Delivery Monitor: User Exits for Filling Display Fields
    V50R0001  Collective processing for delivery creation
    V50R0002  Collective processing for delivery creation
    V50R0004  Calculation of Stock for POs for Shipping Due Date List
    V50S0001  User Exits for Delivery Processing
    V53C0001  Rough workload calculation in time per item
    V53C0002  W&S: RWE enhancement - shipping material type/time slot
    V53W0001  User exits for creating picking waves
    VMDE0001  Shipping Interface: Error Handling - Inbound IDoc
    VMDE0002  Shipping Interface: Message PICKSD (Picking, Outbound)
    VMDE0003  Shipping Interface: Message SDPICK (Picking, Inbound)
    VMDE0004  Shipping Interface: Message SDPACK (Packing, Inbound)
    For Billing VF01..Package is VF..
    SDVFX007  User exit: Billing plan during transfer to Accounting
    SDVFX008  User exit: Processing of transfer structures SD-FI
    SDVFX009  Billing doc. processing KIDONO (payment reference numbe
    SDVFX010  User exit item table for the customer lines
    SDVFX011  Userexit for the komkcv- and kompcv-structures
    V05I0001  User exits for billing index
    V05N0001  User Exits for Printing Billing Docs. using POR Procedu
    V60A0001  Customer functions in the billing document
    V60P0001  Data provision for additional fields for display in lis
    V61A0001  Customer enhancement: Pricing
    Or another way is ..
    - Get the program name for that T-Code
    - Go to that program
    - In that program, search for word 'EXIT' or 'CUSTOMER-FUNCTION' by using where-used list which will give u the list of user exits for that program
    And also you can check in the tables in SE16 for user exits..
    MODSAP - Stores SAP Enhancements
    MODSAPT - Stores SAP Enhancements - Short Texts
    MODACT - Stores Modifications
    And there are other ways as well , pls check the forum for this ,
    Regards,
    Vvieks
    Note : If you have any specific requirement then pls let us know , we will guide you

  • Where can I store global variables.

    Hi All,
    Where can I store global variables. Requirement is, ability to modify and add to the list of global variables. Any modification should be reflected dynamically. One way to do is to store in Entity Beans. I thought storing in DataBase will impact performance. Any advice.
    Appreciate any help.

    Hi,
    If these variables won't changed prgramtically, then store them in Enveroment Variables

  • Regarding how to find out a program is User Exit/executable

    Hi,
    Can anybody tell me how can we find wether a particular program is used in executable program (or) user exit program?
    One thing we can find out is wether the program type is 'I' or 'R' etc..
    Thanks in advance.
    Thanks,
    Deep.

    Hi...
    See the following links..
    it helps you a lot..
    how can we C the USER_EXITS in Z programs
    how can we find the list of user exits for a transaction
    How to find the active user exits in my client
    How to find user exits for a transaction
    Hope it helps you...
    Let me know if u have any more doubt...
    Reward points if useful......
    Suresh.......

Maybe you are looking for