How to capture user input for customer exit processing?

I need to calculate the number of working days elapsed in the current fiscal quarter BASED on the USER INPUT on the reporting front.  i.e., say the fiscal quarter started on 1 July 2005 and if the user enters 10 July 2005, I should get the value 8 (Assume that Monday through Friday are all workdays).  If the user enters 12 July 2005, I should get 10.  I have written customer exits and know how to use factory calendar, but <b>THE CHALLENGE</b> is how do I <b>CAPTURE</b> the user input and use it in my exit?  During the varible definition, if I select the check box "Ready for input" then the customer exit is not being processed and unless I check that box I can't get a user entry!  If I look at the import values in the customer exit, I see i_t_var_range with type rrs0_t_var_range.  My strong feeling is that this parameter gets the user input, but I am unable to use it as the customer exit is not being called if I make the user to input the data.  Based on the empirical evidence, I felt that user input and customer exit can not co-exist!!  Please somebody prove me wrong and let me know how can I use the user input to process my "customer-exit" variable.  I would really appreciate any input from the BW community here.

Hi Sameer,
Most likely, I'm missing something, but I think that the answer is very simple.
CASE I_VNAM.
WHEN 'YOUR_CUSTOMER_EXIT_VAR'.
IF I_STEP = 2. “ After selecting of input variable
LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE
WHERE VNAM = 'USER_INPUT_VAR'.
CLEAR L_S_RANGE.
L_S_RANGE-LOW = LOC_VAR_RANGE-LOW(4).
APPEND L_S_RANGE TO E_T_RANGE.
ENDLOOP.
ENDIF.
ENDCASE.
In this typical user exit coding you have a user entered value in LOC_VAR_RANGE (originally in I_T_VAR_RANGE) and you construct your user exit variable value in E_T_RANGE.
Best regards,
Eugene
Message was edited by: Eugene Khusainov

Similar Messages

  • How to capture user inputs from Enter_query command?

    When the user enters query(F7) and inputs some field parameters...how do I capture those variables after they execute the query?
    Example:
    -Table ABC has a column called NAME
    -They enter '%BOB% in the NAME field
    -They press F8 (enter-query)
    I've tried using:
    message( get_block_property('ABC', DEFAULT_WHERE)) to see what's in there and it returns a null. I know that if I hit F7 twice, I can see '%BOB%' displayed in the field. Is there a way to see this without hitting F7 twice?
    Thanks.

    -Table ABC has a column called NAME
    -They enter '%BOB% in the NAME field
    -They press F8 (enter-query)
    ? F8 = execute-query
    however. Use the PRE-QUERY and write your message there and show the value of :ABC.NAME
    that's it
    Gerd
    PS: Without hitting two times F7 you have NO chance to get the value of %BOB%. this is an internal cache mechanism of the forms runtime and only hitting two times F7 gives you the information which forms has remembered in a local cache.

  • How to force sql developer to prompt for user input for every execution ?

    Hi Folks,
    Environment: Oracle 11g (on Windows 7)
    SQL Developer: *3.1.07*
    I am executing a PL/SQL code off Sql Developer. The code uses substitution variables to prompt user for input. However,I am only prompted for the user input for the very first run of the code. For the subsequent executions, the code simply picks up the user input from the very first run. This behavior persists for all subsequent runs of the code.
    I have executed the same piece of code from SQL*PLUS and the behavior seems normal (i.e. I am prompted for fresh input for every execution)
    How can flush out the old user input so I can be prompted for new user input for every run of the code in sql developer?
    Thanks in advance
    rogers42

    Hi Rogers42,
    1/try
    undefine
    undefine fred
    select '&&fred' from dual;
    [run this multiple times]
    [prompts gere]
    old:select '&&fred' from dual
    new:select 'a' from dual
    'A'
    a
    [prompts here]
    old:select '&&fred' from dual
    new:select 'b' from dual
    'B'
    b
    2/try
    exit (requires recent version of sql developer: tools->preferences->Database->worksheet->Re-initialize on script exit command)
    select '&&fred' from dual;
    exit
    run this multiple times
    [prompts here]
    old:select '&&fred' from dual
    new:select 'x' from dual
    'X'
    x
    Commit
    [prompts here]
    old:select '&&fred' from dual
    new:select 'y' from dual
    'Y'
    y
    Commit
    3/use &fred instead of &&fred
    For background see
    http://totierne.blogspot.co.uk/2010/04/substitution-and-bind-variables.html
    -Turloch
    SQLDeveloper team

  • Owb - Capturing user input classes

    Hi,
    I'm using OWB 9.2.0.3 and I'm looking at creating some OMB*Plus scripts to deploy (instead of using the GUI)
    I noticed in the sample code (on OTN) for OWB, some classes for "capturing user inputs" in OMB*Plus. I think that this would be a great addition to my scripts (instead of hard coding userid and password).
    How do I get this to work? What do I do with these classes? where to put them? and would you have any documentation on how to code this in OMB*Plus.
    Thank you very much.
    Guy LaBelle

    Guy,
    The description is missing... and I will submit this right away to be added. The link will be with the location of the downloadable file. Will be there within the next couple of days.
    Now, without the screenshots (hope this helps to some extend):
    The omb_params zip file contains classes for a generic modal dialog that can be used from OMBPlus for capturing user input. It will support parameters that are text or passwords. If you unzip this file into owb\bin\admin you can try the dialog from OMBPlus.
    The Java can be invoked by calling as follows;
    # java::new oracle.owb.samples.CaptureParams {
    # display_string_list display string for dialog ie. {"Hostname", "Port", "Service"}
    # param_name_list to query after dialog is complete ie. {"vhostname", "vport", "vservice"}
    # param_type_list STRING or STRINGHIDE or list of tokens (comma separated) for combo box
    # title_string_for_dialog Title for the dialog.
    # dialog_prompt_string Prompt string for dialog.
    or
    # java::new oracle.owb.samples.CaptureParams {
    # display_string_list display string for dialog
    # param_name_list to query after dialog is complete
    # param_type_list STRING or STRINGHIDE or list of tokens (comma separated) for combo box
    # title_string_for_dialog
    # dialog_prompt_string
    # ok_button_string
    # cancel_button_string
    or
    # java::new oracle.owb.samples.CaptureParams
    # title_string_for_dialog
    # dialog_prompt_string
    # ok_button_string
    # cancel_button_string
    There is a Java accessor methiod named 'okButton' that will return a boolean (in Java), the Tcl shell will return 0 for false, and 1 for true. This can be used to determine if the user has pressed the OK or cancel button. Since the user can define the text for these buttons, they can be used for Yes/No style questions for example.
    5.1 Example to capture user input;
    The following dialog can be created with the Tcl below;
    The Tcl to create this dialog is show below, this creates a modal dialog to capture the user input for username, password (in password field), connection string and an option selectable from a combo box;
    set pars [java::new {String[][]} 3 {{"User" "Password" "Connect" "Option"} {"user" "pass" "connect" "option"} {"STRING"
    "STRINGHIDE" "STRING" "thick,thin"}} ]
    set jtitle "OWB Migration"
    set jprompt "Please enter migration properties:"
    set paramList [java::new oracle.owb.samples.CaptureParams $pars $jtitle $jprompt]
    # To check whether OK or cancel is pressed used retrieve okButton/cancelButton on object, then check value (0 - false, 1 - true)
    set okpressed [$paramList okButton]
    # To retrieve the parameters invoke getValue passing the parameter name, the user is stord in a variable (for example);
    set userval [$paramList getValue "user"]
    set passval [$paramList getValue "pass"]
    set connectval [$paramList getValue "connect"]
    set optionval [$paramList getValue "option"]
    5.2 Example to create a question-style dialog;
    set paramList [java::new oracle.owb.samples.CaptureParams "OWB Dimensional Design" "Do you want to create a cube?" "Yes" "No"]
    Like the example above the 'okButton'/'cancelButton' methods can be used to query the button that was selected.
    Thanks,
    Mark.

  • Where do I write the code for customer exit variable?

    Hi Gurus,
    Can anyone tell me where and the procedure that I have to follow to get to the include ZXRSRU01 where I can write customer exit variable code.
    I know its written in ZXRSRU01, but in my system it seems like its not active or does not exist. How do I get to start working in this include for customer exit variables?
    Any help is appreciated. Thank you.
    Regards
    Reddy

    hi Reddy,
    variable exit use enhancement RSR00001 not RSAP0001. EXIT_SAPLRRS0_001.
    try to follow some steps in 'how to' doc related to this, and sample code may useful for you
    https://websmp206.sap-ag.de/~sapdownload/011000358700002762582003E/HowToDeriveVariableValue.pdf
    https://websmp206.sap-ag.de/~sapdownload/011000358700002765042003E/HowToVerifyVariableInput.pdf
      INCLUDE ZXRSRU01                                                   *
      DATA: L_S_RANGE TYPE RSR_S_RANGESID.
      DATA: LOC_VAR_RANGE LIKE RRRANGEEXIT.
      CASE I_VNAM.
      WHEN 'CUMMONTH'.
        IF I_STEP = 2.                                  "after the popup
          LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE
                  WHERE VNAM = 'MONTH'.
            CLEAR L_S_RANGE.
            L_S_RANGE-LOW      = LOC_VAR_RANGE-LOW(4)."low value, e.g.200001
            L_S_RANGE-LOW+4(2) = '01'.
            L_S_RANGE-HIGH     = LOC_VAR_RANGE-LOW.   "high value = input
            L_S_RANGE-SIGN     = 'I'.
            L_S_RANGE-OPT      = 'BT'.
            APPEND L_S_RANGE TO E_T_RANGE.
            EXIT.
          ENDLOOP.
        ENDIF.
      ENDCASE.
    hope this helps.

  • To Capture Excise Duties for Customer Material

    Dear All,
    Issue is regarding to capture excise invoice
    for Customer Material.
    1.
    one of our client receives Customer material which
    should not be reflected in
    stock.
    2. Excise should be captured which
    receiving
    3. Now
    when this Customer material is returned back to
    customer along with
    the assembly (i.e. the material received from
    customer is fixed
    in Assembly and sent back to
    customer),
    4. Now
    the excise
    captured should be transfered back to customer's A/c.
    I tried
    doing by creating a material type as customer material, where in
    Stock will be reflected but value will not be reflected, where exactly
    we
    can capture the excise details for this scenario.
    How
    to
    proceed further to complete his scenario.
    Consider this
    issue
    to be on high priority &  i/p will be of great help.

    Dear Vijayashree
    From your comments what I understood is that for a particular FERT, you are procuring one component from the buyer, assembling it and invoicing to the same customer.
    If this is the scenario, I dont know how you can invoice without maintaining BOM for that.
    If the client don’t want to maintain BOM for the same, the only option is as follows to my knowledge.
    Whenever the client receives the component, take credit of the duty amount by updating <b>J1IH</b>. While doing PGI, since you have not maintained this component in BOM, stock will <i>ONLY</i> reduce for other components.  So no-where, your client can track the customer’s component.
    Parallelly, apart from selling price, to the extent of excise duty value, one more condition (say ABCD,  to be maintained.  So in your pricing procedure, the assessable value should be PR00 + ABCD for which, the excise duty should be captured so that the client can recover the duty amount from customer.
    Finally, for this practice, the client should maintain datas (how many procured and how many invoiced) manually to convince the government officials but then, I am not sure, how far this will be accepted by the officials.
    Thanks
    G. Lakshmipathi

  • Error in the ABAP Code for Customer Exit Variable

    Could you please update me what is the wrong with the below ABAP Code developed for Customer Exit Variable in BW
    i created a Variable (ZVWKNO) of Customer Exit,Single Value ,Mandatory and Variable is ready for input
    In CMOD i had written the below Code:
    When 'ZVWKNO'.
    DATA: WEEK(2) TYPE N,
    WEEKNO(2) TYPE N.
    IF i_step = 1.
    l_st_date = SY-DATUM.
    CALL FUNCTION 'DATE_GET_WEEK'
    EXPORTING
    DATE = l_st_date
    IMPORTING
    WEEK = l_fn_week.
    CHECK sy-subrc = 0.
    WEEK = l_fn_week+4(2).
    If WEEK 0.
    WEEKNO = WEEK - 1.
    l_s_range-low = WEEKNO.
    l_s_range-sign = k_sign_inclusive.
    l_s_range-opt = k_option_equals.
    APPEND l_s_range to e_t_range.
    ENDIF.
    ENDIF.
    But when i execute the query the default value is not populated with Week-1 No in the variable screen
    Please update me what went wrong
    Thanks

    Case ZVWKNO.                "write this with out comments
    When '1'.              "write the value that needs to equal with value in varaible ZVWKNO after when in sungle quotes
    DATA: WEEK(2) TYPE N,
    WEEKNO(2) TYPE N.
    IF i_step = 1.
    l_st_date = SY-DATUM.
    CALL FUNCTION 'DATE_GET_WEEK'
    EXPORTING
    DATE = l_st_date
    IMPORTING
    WEEK = l_fn_week.
    CHECK sy-subrc = 0.
    WEEK = l_fn_week+4(2).
    If WEEK 0.                                    "check this Week Minimum is '01' and Maximum '52'
    WEEKNO = WEEK - 1.
    l_s_range-low = WEEKNO.
    l_s_range-sign = k_sign_inclusive.
    l_s_range-opt = k_option_equals.
    APPEND l_s_range to e_t_range.
    ENDIF.
    ENDIF.
    Prabhudas

  • ABAP Help for customer exit

    Hi All, I need help with ABAP code for customer exit for formula variable. I have ZVKDATE as formula var from customer exit. user enters date in ZVKEYDT(this is selection type var). I have the below code, I debugged it the l_var_range-low get the date but when I append it to e_t_range the table doesn't gets the date. The report shows the ZVKDATE has empty demarcation. kindly help.
    data l_var_range like rrrangeexit.
    data: l_s_range type RSR_s_RANGESID.
    data: w_day(2) type c,
          w_mth(2) type c,
          w_year(4) type c.
    define append_range_table.
    l_s_range-low = &1.
    l_s_range-sign = 'I'.
    l_s_range-opt = 'EQ'.
    append l_s_range to e_t_range.
    end-of-definition.
    *Activities performed before selection screen pop-up window
    if i_step = 2.
    Calculate the current date based on system date
      case i_vnam.
        when 'ZVKDATE'.
          read table i_t_var_range into l_var_range
                            with key vnam = 'ZVKEYDAT'.
          l_s_range-sign = 'I'.
          l_s_range-opt = 'EQ'.
          w_day = l_var_range-low+6(2).
          w_mth = l_var_range-low+4(2).
          w_year = l_var_range-low(4).
          concatenate w_year w_mth w_day into l_var_range-low.
          append l_s_range to e_t_range.
      endcase.
    endif.
    puneet

    Hi,
    Check your code again. You are not appending l_var_range but l_s_range. Also I think the concatenate statement should contain l_s_range-low instead of l_var_range-low.
    Hope this will help you.
    Regards,
    Vaibhav

  • How to create user group for EIS (Executive Information System) KCBA

    Dear Experts,
    How to create user group for EIS (Executive Information System)
    TCode KCBA
    Regards
    Saurabh

    Hi ,
    Check the below link ,hope it will give some inputs for creating groups.
    http://help.sap.com/saphelp_470/helpdata/en/5c/c1c81c445f11d189f00000e81ddfac/content.htm
    Regards
    udayakumar.k

  • Change package for Customer Exit

    How can I change a package for Customer Exit? I can't find the Cusomter Exits project by using SE80 transaction... :/

    Hi
    To change the package for the customer exit
    1) use tcode CMOD
    2) frm the GOTO menu , choose OBJECT DIRECTORY ENTRY.
    3.in the OBJECT DIRECTORY ENTRY , go to change mode , frm there u can change ur package also.
    Assign points if helpfull
    From
    ManesH

  • Require User Input for either dashboard prompts not BOTH ! !

    Fellow Earthlings,
    How to make required for user input for either of dashboard prompts not BOTH. !!!!!!
    Like if they enter '123' on DashP1 they need not have to enter DashP2 value and vice versa on same dashboard prompt.
    I have some dashboard prompts and I am using presentation variables to pass these values to my analysis.
    DashP1 - Pvar1 - Default All columns - User can type in values
    DashP2 - Pvar2 - Default All columns - User can type in values
    In my report , I am using a SQL filter to do a table.column_name LIKE (concat('@Pvar1}{'%')) same for the other table.column_name LIKE (concat('@Pvar2}{'%')) [ This is because users want to do a partial match on the value.
    So when the user is typing the values like 123 on DashP1 they are able to search, which is good. However on DashP2 which defaulted to all column values, they just erase/delete that and pass no value to it. So it remains the prompt vlaue is looking like -Select Value state which is not good. :(
    Now when there report is run for that DashP1 -value as '123' obviously we get no results since erasing that is causing it not to pass any value and when i check the query log it passes '@Pvar2'. This is causing no results.
    So I thought making it Required user input would resolve the issue, however the new request is to have either DashP1 or DashP2 require user input.
    Please advice if there a way to solve this problem.
    If this any way possible with Action links or any other methods.
    Any help is greatly appreciated.
    Thanks,
    VidyaS

    Hi Vidya, Please post that Script it will be quite handy for other OTN users.
    Thanks
    NK

  • How to get User input in JTextField?

    How to get User input in JTextField? Can u anyone give me some code samples? thanks

    read the API!!!

  • How to capture the screen for sending the mail

    dear sir,
                      How to capture the screen for sending the mail .. Is there any funtion module or anyother way ? .. How to do this .. Please tell me..
    Regards,
    Kumar

    dear sir,
    s thats my problem ?
    Regards,
    kumar

  • Variable Offset for Customer Exit??

    Hi,
    is it possible to have a variable offset for customer exit time variables?
    E.g. I have a variable current month but can I also create a one-year offset of that?
    In our system that doesn't work (but also the current month variable doesn't work...)
    thanks
    Sabine

    Hi,
    As it is mentioned by Mr.Voodi,it definately works.
    You only has given the answer for your problem .i.e you need to make sure the Customer exit variable is working proper.So take a look on the code used for it.
    With rgds,
    Anil Kumar Sharma .P

  • How to take user input and place it in a variable

    All I want to know is how to copy user input from the message pop up and store in a local variable?
    Thanks.

    Hi
    Just take a look at thread's example
    http://forums.ni.com/t5/NI-TestStand/TestStand-Message-Popup/m-p/1792424/highlight/true#M35397
    The trick is done by Message-Popup PostExpression: Locals.strMyResponse = Step.Result.Response
    Hope this helps
    Juergen
    =s=i=g=n=a=t=u=r=e= Click on the Star and see what happens :-) =s=i=g=n=a=t=u=r=e=

Maybe you are looking for