Exits for saving variant of selection screen

Hi,
My need is that I have to validate the name of the variant on saving. If the name is not in compliance then we will put a tick on a checkbox on screen and save it. So to do this can anyone suggest me the exit name or BADI name.
thanks in advance.

Hi,
Code should as below.
IF I_STEP = 3 .
    LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE WHERE VNAM = 'VAR1' OR
VNAM = 'VAR2' .
ENDLOOP.
      IF SY-SUBRC NE 0 .
        CALL FUNCTION 'RRMS_MESSAGE_HANDLING'
         EXPORTING
           I_CLASS                    = 'RSBBS'
           I_TYPE                     = 'E'
           I_NUMBER                   = '000'
           I_MSGV1                    = 'Enter Either one of the variable'
         EXCEPTIONS
           DUMMY                      = 1
           OTHERS                     = 2.
           RAISE NO_PROCESSING.
      ENDIF.
ENDIF.

Similar Messages

  • Customer exits for varibles in BeX selection screen

    Dear All,
    I have two fields in BeX variable screen - 'Emp_id' and 'Dep_id'.
    The entry for 'Emp_id' is mandatory. But at the same time, if someone does not enter values for it, it should ask for 'Dep_id' atleast. If both are blank, then no execution.
    In short, if both fields are blank then don't run the report. If one of them has a value, then run the report.
    I know that for this case of mine, customer exit is the only way.
    Can anybody please write me the exact syntax of the exit as I am least aware of writing the exits. Thanking you all.
    Points will be assigned.
    Thanks,
    Srinivas

    Hi,
    Code should as below.
    IF I_STEP = 3 .
        LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE WHERE VNAM = 'VAR1' OR
    VNAM = 'VAR2' .
    ENDLOOP.
          IF SY-SUBRC NE 0 .
            CALL FUNCTION 'RRMS_MESSAGE_HANDLING'
             EXPORTING
               I_CLASS                    = 'RSBBS'
               I_TYPE                     = 'E'
               I_NUMBER                   = '000'
               I_MSGV1                    = 'Enter Either one of the variable'
             EXCEPTIONS
               DUMMY                      = 1
               OTHERS                     = 2.
               RAISE NO_PROCESSING.
          ENDIF.
    ENDIF.

  • Adding layout variant to selection screen

    Hi all,
             Currently I am working on report program, where I have to allow user to select his own output pattern. i.e layout variant is to be added to selection screen. The report uses object oriented ALV for display purpose. [set_table_for_first_display]
    I made following steps,
    1.     Declared one parameter of type disvariant.
    2.     At selection-screen on value-request I called function REUSE_ALV_VARIANT_F4.
    3.     Passed internal table to method set_table_for_first_display.
    Now I am able to create save new variant, on selection screen I can select the variant that I have created, but output shows the all the fields though
    Only few are selected. Please tell me any modification so as to reflect the changes in output.
    I  am searching for a function which maintains fieldcat according to user defined variant.
    Regards,
    Nilesh kulkarni.

    U have to use REUSE_ALV_VARIANT_EXISTENCE inorder to use the layout u have selected
    After ur code of REUSE_ALV_VARIANT_F4.
    try this way
    AT SELECTION-SCREEN.
       PERFORM PAI_OF_SELECTION_SCREEN.
    G_REPID = SY-REPID.
    G_SAVE = 'A'.
    FORM PAI_OF_SELECTION_SCREEN .
      IF NOT P_LAYOUT IS INITIAL.
        MOVE G_VARIANT TO GX_VARIANT.
        MOVE P_LAYOUT TO GX_VARIANT-VARIANT.
        CALL FUNCTION 'REUSE_ALV_VARIANT_EXISTENCE'
             EXPORTING
                  I_SAVE     = G_SAVE
             CHANGING
                  CS_VARIANT = GX_VARIANT.
        G_VARIANT = GX_VARIANT.
      ELSE.
        PERFORM VARIANT_INIT.
      ENDIF.
    ENDFORM.                    " PAI_OF_SELECTION_SCREEN
    FORM variant_init .
      CLEAR G_VARIANT.
      G_VARIANT-REPORT = G_REPID.
    ENDFORM.                    " variant_init
    Then when u call ALV for display, pass ur display variant, in this case  = g_variant
    Reward if useful
    Cheers
    ~Arun
    Message was edited by:
            Arun Shekhar

  • How to set Variant as selection-screen

    I have a variant i want to set that variant as selection-screen can anyone please tell me how to do that

    Hi Pradeep,
    What is your requirement?
    If you just want to create the variant for the selection screeen, then after entering the values on selection screen just press SAVE button.
    Regards,
    Atish

  • Specify printer for payment summary, or select screen output

    Hi All,
    I have scheduled a Job using F110 tcode...with Run ID and identification...the job is continously running without any end...when i cancel the job..in job log entries i got "Specify printer for payment summary, or select screen output
    Message no. BFIBL02 615" ...what could be the reason behind this..do i need to specify printer any where??
    Kindly help

    Hi
    tru to check the variant you're using for the report to print the payment advises or the list of payment
    Here you need to indicate the printer
    Max

  • Popup Menu(F1- Help values) is not diaplying for a char at selection screen

    Hi,
    After executed the query, we are trying to get help (F4) values for info object Employee Group (EMPLGROUP) in the selection screen but it is taking long time nearly 1 hr and getting timed out. And for other Chars we are getting the help popup menu.
    for your info...     
    There are only 6 values are there in Employee Group master data table.
    And the characteristic settings in Business Explorer tab are as the following,
    Display u2013 Text
    Text type u2013 Default
    BEx description u2013 Short description
    Selection u2013 No selection Restriction
    Query Def. Filter Value Selection u2013 Only values in Infoprovider
    Query Execution Filter Val. Selection u2013 Only Posted Values for Navigation
    Can any one please suggest us which settings we needs to change to get the popup menu (help values) for Employee Group at selection screen and what is the reason for not displaying the help popup menu?.
    and can any one explain us about the setting "Query Execution Filter Val. Selection u2013 Only Posted Values for Navigation"
    Thanks & Regards,
    Raju. E

    Hi,
    I am getting the data aslo for Employee Group in the query when I drill down that char.
    But I dont know why it is taking long time and getting time out to display the popup menu for help values at selection screen.
    I think this is due to the below setting only at char level,
    Query Execution Filter Val. Selection u2013 Only Posted Values for Navigation
    and there are 3 opstions for the above seeting as below,
    1. Only values in master data
    2. Only values in Infoprovider
    3. Only Posted Values for Navigation
    Can any one help me, which opstion will solve the issue and can any one explain me what is the difference between 2 & 3
    Thanks,
    Raju. E

  • Code for execute button on selection screen to get result

    hi experts,
    I need a help for writing a code for execution button on selection screen.Like in normal report on abap editor
    we insert selection criteria like number and we get the result according that particular number on next screen.
    same thing i am trying here also. So i am writing a code on button that when i press the button it will go to the next
    screen according to the selection criteria.
    Plz help me helpful answers are appriatiated !!!
    Thanks & regards
    Vipul Gupta

    hi,
    In the OnAction write :
    1. get the values entered in selection criteria using :
    DATA lo_nd_cn_check TYPE REF TO if_wd_context_node.
        DATA lo_el_cn_check TYPE REF TO if_wd_context_element.
        DATA ls_cn_check TYPE wd_this->element_cn_check.
        DATA lv_ca_check LIKE ls_cn_check-ca_check.
      navigate from <CONTEXT> to <CN_CHECK> via lead selection
        lo_nd_cn_check = wd_context->get_child_node( name = wd_this->wdctx_cn_check ).
      get element via lead selection
        lo_el_cn_check = lo_nd_cn_check->get_element(  ).
      get single attribute
        lo_el_cn_check->get_attribute(
          EXPORTING
            name =  `CA_CHECK`
          IMPORTING
            value = lv_ca_check ).
    Now lv_ca_check has your value entered in Selection criteria.
    2.  write the select query to fetch data according to selection criteria.
        select *  from <table> into correponding field of table <internl table>
           where Field = lv_ca_check.
    3. Now in the internal table <internl table> you have values according to search criteria.
    4. Bind the internal table with node  which is binded to table to show data.
    lo_nd->bind_table( internaltable ).
    I hope it is clear .

  • User exits for saving in IQ02 transaction.

    Hi All,
    I have the following problem: The end user is unable to save few fields (Stock type, plant, storage location) data in IQ02 transaction.
    1. Enter IQ02 transaction, give the material and serial number.
    2. In SerData tab, give the stock type, plant and storage location
    3. Now when I am trying to save, the following error is prompted: "System status ESTO is active (EQU 30055392)"
    4. After this when I press continue button, the data is not saved.
    I feel that there could be some problem in the user exits for this transaction. Please tell me the user exits for saving in this transaction.
    Thanks,
    Vishal.

    Hi Vishal,
    Please find list of userexit for Tcode IQ02 as below,
    Exit Name           Description
    IEQM0001            Add. checks for equip. installation at functional locations
    IEQM0002            Additional checks for definition of equipment hierarchies
    IEQM0003            Additional checks before equipment update
    IEQM0004            Object is allowed for contract partner (Order->MaintCont.)
    IEQM0005            Object allowed for SD contract (MaintContract->MaintCont.)
    IEQM0006            Object allowed for SD contract (Maintain maintenance cont.)
    IEQM0007            Check/change manufacturer field in equipment master.

  • How to create tcode for modulepool program with selection screen?

    hi,
       How to create tcode for modulepool program with selection screen?
    thanks,
    sagar

    Hi,
    We need to goto SE80.
    In our program we right click on object name and goto create
    -> transaction. Enter the module pool program and screen number and save and activate.
    Or by SE93 also we can create a transaction code for our program.
    Hope ths helps.
    plz reward if useful.
    thanks,
    dhanashri..
    Edited by: Dhanashri Pawar on Jul 22, 2008 8:29 AM

  • How to create a variant for a program without selection screen

    Hi All,
    I've created one program which takes the data from 30 tables and loads into one final table.
    This program is already moved to Production.
    But while creating variant it's not allowing, since the program doesn't have the selection screen.
    Is there anyway where I can create a variant in production without selection screen directly as the program code is already moved to production.
    Thank You,
    Regards,
    Karthik.Ch

    Hi ,
    Are you running this program in a process chain??

  • Background processing for ABAP report with selection screen

    Hi ABAP Gurus,
    I m facing a strange problem in scheduling a background job for my report with a selection screen. I have a variant for the report.
    I scheduled a job, but it seems to be not doing anything though all the system resources are available. The job overview shows "Acive" for the job. The job is neither stopping anything, it is just sitting there In SM50, the status shows "On Hold".
    Any ideas/comments on the problem and how this can be overcome?
    Qucik replies and solutions will be highly appreciated as this is a crucial part for a go-live project.
    Thanks in advance.
    Shivani.

    Yes. My report has a selection-screen which requires user input. But I have created  a variant for the report and trying to run it in background using this variant. But facing this problem.
    Strange thing is, instead of the usual SM36/SM37 option where we schedule and monitor background jobs, this option does not work for my report.
    But I tried through SE38, and from my selection screen I selected "Schedule background job" and "run immediately" option, and this works. Though I still use SM37 to monitor this background job.
    I have never faced such a situation before.
    Any hints/tips why this happens and how this can be overcome in the future?
    Thanks in advance.
    Shivani.

  • How to run the variable exit without calling the variable selection screen?

    Hi all
    I have a query with 2 variables 0P_PRQUA (Previous Calendar Quarter (SAP Exit)) and ZCCDAT02.
    ZCCDAT02 is a Key Date variable that is derived based on the last day of the quarter that is entered in 0P_PRQUA. The exit code works correctly when calling up the variable screen and ZCCDAT02 is derived properly.
    The problem is that 0P_PRQUA is set to "Can be changed in query navigation". So if the user changes the value of the quarter the exit is not triggered and the value of ZCCDAT02 does not change.
    Is it possible to trigger the exit or is there another way to do it? Ideas would be appreciated. I am trying to create a Web Template with a Dropbox box for the Quarter.
    Query is written in BW 3.X.
    Regards
    Chami

    Hi guys
    Just to restate the requirement. I want the user to be able to change the value of the variable, WITHOUT calling the variable selection screen.
    I want the user to be able to change the value of the quarter by using a dropdown box from within the web template. Once that is selected I want the value of ZCCDAT02 to be derived from the new value of the quarter.
    Regards
    Chami

  • Layout variants in Selection screen

    Hi All,
        I have a requirement where i need to create a functinal key on selection screen'Disp Variant' and i need to provide F4 help when user click on button and when layout is selected the report should show the layout according to selected layout variant.
    I have written following code but it is not workin for me.Please help.
    initialisation.
        wa_functxt-icon_id   =  icon_variants.
        wa_functxt-quickinfo = 'CHOOSE'.
        wa_functxt-icon_text = 'DISP VAR'.
        sscrfields-functxt_01 = wa_functxt.
    wa_functxt of type smp_dyntxt and sscrfields have been declared at top.
    CLEAR: wa_variant2.
      wa_variant2-report = sy-repid.
      CALL FUNCTION 'REUSE_ALV_VARIANT_DEFAULT_GET'
        EXPORTING
          i_save     = ' '
        CHANGING
          cs_variant = wa_variant2
        EXCEPTIONS
          not_found  = 2.
      IF sy-subrc EQ 0.
        PERFORM f_select_alv_variant.
      ENDIF.
    even this is in initialisation.
    form F_SELECT_ALV_VARIANT .
      MOVE sy-repid TO wa_variant1-report.
      CALL FUNCTION 'REUSE_ALV_VARIANT_SELECT'
        EXPORTING
          i_dialog            = space
          i_user_specific     = 'X'
          i_default           = space
          it_default_fieldcat = i_fieldcat[]
          i_layout            = wa_layout
        IMPORTING
          et_fieldcat         = i_fieldcat[]
        CHANGING
          cs_variant          = wa_variant2
        EXCEPTIONS
          wrong_input         = 1
          fc_not_complete     = 2
          not_found           = 3
          program_error       = 4
          OTHERS              = 5.
      IF sy-subrc EQ 0.
        "Do nothing.
      ENDIF.
    endform.  
    AT SELECTION-SCREEN.
    CASE sscrfields-ucomm.
    *When Display Variant button is clicked
        WHEN c_fc01.
          PERFORM f_f4_for_variant.
        WHEN OTHERS.
      ENDCASE.
    form F_F4_FOR_VARIANT .
      CLEAR: wa_variant1,
             wa_variant2.
      wa_variant1-report = sy-repid.
      CALL FUNCTION 'REUSE_ALV_VARIANT_F4'
        EXPORTING
          is_variant = wa_variant1
          i_save     = 'U'
        IMPORTING
          e_exit     = v_variant_exit
          es_variant = wa_variant2.
      PERFORM f_select_alv_variant.
      IF v_variant_exit EQ 'X'..
        PERFORM f_get_default_variant.
      ENDIF.
    endform.
    Thanks in Advance,
    Anjana

    Let's discuss based on something. On that program, I don't have any issue, check it.
    INCLUDE <icon>.
    TABLES sscrfields.
    DATA wa_variant1 TYPE disvariant.
    DATA wa_variant2 TYPE disvariant.
    SELECTION-SCREEN FUNCTION KEY 1.
    PARAMETERS dummy.
    INITIALIZATION.
      DATA wa_functxt TYPE smp_dyntxt.
      wa_functxt-icon_id = icon_variants.
      wa_functxt-quickinfo = 'CHOOSE'.
      wa_functxt-icon_text = 'DISP VAR'.
      sscrfields-functxt_01 = wa_functxt.
      PERFORM f_get_default_variant.
    FORM f_get_default_variant.
      CLEAR: wa_variant2.
      wa_variant2-report = sy-repid.
      CALL FUNCTION 'REUSE_ALV_VARIANT_DEFAULT_GET'
        EXPORTING
          i_save     = ' '
        CHANGING
          cs_variant = wa_variant2
        EXCEPTIONS
          not_found  = 2.
    ENDFORM.                    "f_get_default_variant
    AT SELECTION-SCREEN.
      PERFORM at_selection_screen.
    *&      Form  at_selection_screen
    *       text
    FORM at_selection_screen.
      CASE sscrfields-ucomm.
    *When Display Variant button is clicked
        WHEN 'FC01'.
          PERFORM f_f4_for_variant.
        WHEN 'ONLI'.
          DATA gt_output TYPE TABLE OF t000 WITH HEADER LINE.
          SELECT * FROM t000 INTO TABLE gt_output.
          DATA lo_table TYPE REF TO cl_salv_table.
          TRY.
              CALL METHOD cl_salv_table=>factory
                IMPORTING
                  r_salv_table = lo_table
                CHANGING
                  t_table      = gt_output[].
            CATCH cx_salv_msg.
          ENDTRY.
          DATA lo_layout TYPE REF TO cl_salv_layout.
          lo_layout = lo_table->get_layout( ).
          lo_layout->set_save_restriction( cl_salv_layout=>restrict_none ).
          DATA ls_layout_key TYPE salv_s_layout_key.
          ls_layout_key-report = sy-repid.
          lo_layout->set_key( ls_layout_key ).
          DATA l_variant TYPE slis_vari.
          l_variant = wa_variant2-variant.
          lo_layout->set_initial_layout( l_variant ).
          DATA lo_functions_list TYPE REF TO cl_salv_functions_list.
          lo_functions_list = lo_table->get_functions( ).
          lo_functions_list->set_all( ).
          lo_table->display( ).
      ENDCASE.
    ENDFORM.                    "at_selection_screen
    FORM f_f4_for_variant .
      CLEAR: wa_variant1, wa_variant2.
      wa_variant1-report = sy-repid.
      DATA v_variant_exit TYPE flag.
      CALL FUNCTION 'REUSE_ALV_VARIANT_F4'
        EXPORTING
          is_variant = wa_variant1
          i_save     = 'U'
        IMPORTING
          e_exit     = v_variant_exit
          es_variant = wa_variant2.
      IF v_variant_exit EQ 'X'..
        PERFORM f_get_default_variant.
      ENDIF.
    ENDFORM.                    "F_F4_FOR_VARIANT

  • User exit for saving a sales order

    hi
    wats the user exit when saving a sales order?

    Hi,
    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
    tables : modsap
    tcode : cmod,smod
    Reward if usefull

  • Is it possible to create a variant without selection screen

    Hi,
    I would like to create a variant for a report(Standard report). It does not have selection screen. Could someone tell me is it possible to creste a varaint for it?
    Is it possible to create a variant w/o selection screen? if yes, how?

    If some SELECT-OPTIONS are hidden or NO-DISPLAY, you should be able to create a variant for the report.
    Rob

Maybe you are looking for

  • Adding a link to a web page

    Hi, I'm trying to add a link to a web page to my project, but the url appears as regular text in the project and in the preview. I've tried to search the cp help, the forum and the knowledge base for a way to do it, and didn't find anything. Is it po

  • Type "/TDM/9_600C00001" is unknown - TDMS ABAP Dump

    Good afternoon, I'm starting the data transfer phase in my TDMS package and I've run across the following error message. TDMS created all the reports it needs for data deletion in the receiver system, but all the reports have a syntax error causeing

  • Need help installing Control panel for Creative Roar speaker!!!

    I am trying to download the control panel to my Windows XP PC, or my Windows 8 laptop but when I download the try to install the control panel both my PC & laptop says, Setup unable to detect a supported product on your system. What does that mean?

  • Flexible upload log showns no values

    Hi All, We are uploading transaction data through Flexible upload method. After update data log shows no values under Local Currency and Quantity. Please let me know, why system behaving like this. How to Regards SVNR

  • AP Config

    HI, Can anyone help me how to cofigure AIR-CAP2602I-E-K9 Version 15.2(2)JB I am struggling to get into configure mode like we do in normal cisco devices. I can understand it is bit different in this version. i think wee need to use capwap & lwapp Can