How to verify ... variable input

To whom it may concern,
I am referring to this SAP document which suggest that we can verify
the variable entry with a message pop up.
1- How To ... Verify Variable Input.pdf SAP Document 
Another BW Expert Online document talks about the same solution
2 - "Add Pop-Up Messages to BEx Queries for Simple Validation and Feedback "
I have tried to implement these solutions, but they do not seem to work as they were printed.  I have been in communication with SAP and they have indicated the same.
I have found a number of items not to work:
1) The RAISE again statement gives an error when the project is
activated
2) The variable. Should this not be Customer Exit. IN the picture it
is indicated as user entry.
3) This does not seem to work in the web. Only in the BEx Analyzer.
Do you have any solutions that work in the web.
Basically, what I am trying to implement a solution that checks the variable input
entry before executing the query via the web.
Thank you.
Simon Haddad
[email protected]
PS For anyone who is interested in the code that i have used:
I have looked at the Online help , (the second one)
when i put as mentioned RAISE no_processing, then this is the error that comes up:
"NO_PROCESSING" is not defined as an exception in the function module.
Here is my Code:
Custom message variables for Value Type ** ZM_VTYP# Message User Exit Variable with Value Type from ZS_VTYP# ** ** BW Expert Solution ** Add Pop-Up Messages to BEx Queries for Simple Validation & Feedback ** WBHADS - 15/11/2006 *************************************************************************
WHEN 'ZM_VTYP1' OR
'ZM_VTYP2' OR
'ZM_VTYP3'.
IF i_step = 2.
CLEAR l_s_range.
CLEAR loc_var_range.
CLEAR loc_var_range2.
CONCATENATE 'ZS_VTYP' i_vnam+7(1) INTO var_name.
CONCATENATE 'ZS_VTYP' '1' INTO var_name.
LOOP AT i_t_var_range INTO loc_var_range
WHERE vnam EQ var_name.
Pop-up messages can include warning (W) and error (E) messages as well* as success (S) and information (I) messages.
if loc_var_range-low eq 20 or loc_var_range-low eq 60.
CONCATENATE 'ZS_VERC' i_vnam+7(1) INTO var_name.
CONCATENATE 'ZS_VERC' '1' INTO var_name.
LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE2
WHERE VNAM = var_name.
ENDLOOP.
CONCATENATE 'Please Input Version for Value Type'
i_vnam+7(1) INTO l_message SEPARATED BY ' '.
CONCATENATE 'Please Input Version for Value Type' '1'
INTO l_message SEPARATED BY ' '.
IF LOC_VAR_RANGE2-LOW EQ ''.
CALL FUNCTION 'RRMS_MESSAGE_HANDLING'
EXPORTING
I_class = 'RSBBS'
I_type = 'I'
I_number = '000'
i_msgv1 = l_message
i_msgv2 = l_msgv2 “change
i_msgv3 = l_msgv3
EXCEPTIONS
Dummy = 0.
OTHERS = 0.
CALL FUNCTION 'RRMS_MESSAGES_SHOW'.
CALL FUNCTION 'RRMS_MESSAGES_DELETE'.
If you want to terminate the processing of the query after the pop-up
message appears, you must include the RAISE again. This stops the
processing of the query so you can return to the selection screen and
enter a valid value
RAISE AGAIN.
RAISE no_processing.
Endif.
ENDIF.
ENDLOOP.
CLEAR l_s_range.
CLEAR loc_var_range.
CLEAR loc_var_range2.
CONCATENATE 'ZS_VTYP' '2' INTO var_name.
LOOP AT i_t_var_range INTO loc_var_range
WHERE vnam EQ var_name.
Pop-up messages can include warning (W) and error (E) messages as well* as success (S) and information (I) messages.
if loc_var_range-low eq 20 or loc_var_range-low eq 60.
CONCATENATE 'ZS_VERC' '2' INTO var_name.
LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE2
WHERE VNAM = var_name.
ENDLOOP.
CONCATENATE 'Please Input Version for Value Type' '2'
INTO l_message SEPARATED BY ' '.
IF LOC_VAR_RANGE2-LOW EQ ''.
CALL FUNCTION 'RRMS_MESSAGE_HANDLING'
EXPORTING
I_class = 'RSBBS'
I_type = 'I'
I_number = '000'
i_msgv1 = l_message
i_msgv2 = l_msgv2 “change
i_msgv3 = l_msgv3
EXCEPTIONS
Dummy = 0.
OTHERS = 0.
CALL FUNCTION 'RRMS_MESSAGES_SHOW'.
CALL FUNCTION 'RRMS_MESSAGES_DELETE'.
If you want to terminate the processing of the query after the pop-up
message appears, you must include the RAISE again. This stops the
processing of the query so you can return to the selection screen and
enter a valid value
RAISE AGAIN.
Endif.
ENDIF.
ENDLOOP.
CLEAR l_s_range.
CLEAR loc_var_range.
CLEAR loc_var_range2.
CONCATENATE 'ZS_VTYP' '3' INTO var_name.
LOOP AT i_t_var_range INTO loc_var_range
WHERE vnam EQ var_name.
Pop-up messages can include warning (W) and error (E) messages as well* as success (S) and information (I) messages.
if loc_var_range-low eq 20 or loc_var_range-low eq 60.
CONCATENATE 'ZS_VERC' '3' INTO var_name.
LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE2
WHERE VNAM = var_name.
ENDLOOP.
CONCATENATE 'Please Input Version for Value Type' '3'
INTO l_message SEPARATED BY ' '.
IF LOC_VAR_RANGE2-LOW EQ ''.
CALL FUNCTION 'RRMS_MESSAGE_HANDLING'
EXPORTING
I_class = 'RSBBS'
I_type = 'I'
I_number = '000'
i_msgv1 = l_message
i_msgv2 = l_msgv2 “change
i_msgv3 = l_msgv3
EXCEPTIONS
Dummy = 0.
OTHERS = 0.
CALL FUNCTION 'RRMS_MESSAGES_SHOW'.
CALL FUNCTION 'RRMS_MESSAGES_DELETE'.
If you want to terminate the processing of the query after the pop-up
message appears, you must include the RAISE again. This stops the
processing of the query so you can return to the selection screen and
enter a valid value
RAISE AGAIN.
Endif.
CALL FUNCTION 'RRMS_MESSAGES_SHOW'.
CALL FUNCTION 'RRMS_MESSAGES_DELETE'.
ENDIF.
ENDLOOP.
l_s_range-low = loc_var_range-low.
l_s_range-sign = 'I'.
l_s_range-opt = 'EQ'.
APPEND l_s_range TO e_t_range.
ENDIF.

Hi San!
Are you able to send me a working copy of one of your bits of code.
Thank you for you analysis.  Still some issues however,  and there are some debugging issues:
If you can further assist, here is the design of our query:
-  i have the following user entry variables ZS_VTYP1, ZS_VTYP2 and ZS_VTYP3 for the characteristice 0VTYPE - Value Type.
-  i have the following user entry variables ZS_VTYP1, ZS_VTYP2 and ZS_VTYP3 for the characteristic 0VERSION - Version.
If you put value type 60 (Forecast) in any or all of the value type user entry variables, then you must put a corresponding version identifier, eg. F1
Hence this is where the message that is required.
Otherwise, if Value type 10, or 20 Actual or Plan is entered, then it is fine.
I have put tabs in the code you sent me, but it seems to debug
with these 2 messages:
WHEN is only allowed after case
="... " Expected after RAISE
I have tried to interperet your logic here:
WHEN is only allowed after case
="... " Expected after RAISE
Custom message variables for Value Type                             *
ZM_VTYP# Message User Exit Variable with Value Type from ZS_VTYP#   *
BW Expert Solution                                                  *
Add Pop-Up Messages to BEx Queries for Simple Validation & Feedback *
WBHADS - 15/11/2006                                                 *
Userid: San! Message: How to verify ... variable input              *
Posted: Dec 15, 2006 3:46 AM                                        *
www.sdn.com - 18/12/2006                                            *
1) Verification of input variable is done in I_STEP = 3.
2) I_STEP =2 is called for all variable(Customer exit type).
3) i_STEP =3 is called only once for all variable.
1) The RAISE again statement gives an error when the project is
activated---Your Activate..that is not problem..go ahead with that.
2) Variable can be Customer exit..i have done this...
3) It work in Web also..
ZS_VTYP3 is a user-entry varibale and ZS_VERC3 is customer exit
variable.
CASE I_VNAM.
   WHEN 'ZM_VTYP1' OR
     'ZM_VTYP2' OR
     'ZM_VTYP3'.
     IF I_STEP = 2.
     WHEN 'ZS_VERC3'
          CLEAR l_s_range.
          CLEAR loc_var_range.
          CLEAR loc_var_range2.
          CONCATENATE 'ZS_VTYP' '3' INTO var_name.
          LOOP AT i_t_var_range INTO loc_var_range
                    WHERE vnam EQ var_name.
          ENDLOOP.
          l_s_range-low = loc_var_range-low.
          l_s_range-sign = 'I'.
          l_s_range-opt = 'EQ'.
          APPEND l_s_range TO e_t_range.
     ENDIF.
ENDCASE.
IF i_step = 3.
     CLEAR l_s_range.
     CLEAR loc_var_range.
     CLEAR loc_var_range2.
     CONCATENATE 'ZS_VTYP' i_vnam+7(1) INTO var_name.
     CONCATENATE 'ZS_VTYP' '1' INTO var_name.
     LOOP AT i_t_var_range INTO loc_var_range
               WHERE vnam EQ var_name.
     if loc_var_range-low eq 20 or loc_var_range-low eq 60.
          CONCATENATE 'ZS_VERC' i_vnam+7(1) INTO var_name.
          CONCATENATE 'ZS_VERC' '1' INTO var_name.
          LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE2
                    WHERE VNAM = var_name.
          ENDLOOP.
          CONCATENATE 'Please Input Version for Value Type'
*                     i_vnam+7(1) INTO l_message SEPARATED BY ' '.
          CONCATENATE 'Please Input Version for Value Type' '1'
                    INTO l_message SEPARATED BY ' '.
          IF LOC_VAR_RANGE2-LOW EQ ''.
          CALL FUNCTION 'RRMS_MESSAGE_HANDLING'
               EXPORTING
                    I_class = 'RSBBS'
                    I_type = 'I'
                    I_number = '000'
                    i_msgv1 = l_message
                    i_msgv2 = l_msgv2 “change
                    i_msgv3 = l_msgv3
               RAISE no_replacement.
          Endif.
     ENDIF.
     ENDLOOP.
     CLEAR l_s_range.
     CLEAR loc_var_range.
     CLEAR loc_var_range2.
     CONCATENATE 'ZS_VTYP' '2' INTO var_name.
     LOOP AT i_t_var_range INTO loc_var_range
               WHERE vnam EQ var_name.
     if loc_var_range-low eq 20 or loc_var_range-low eq 60.
          CONCATENATE 'ZS_VERC' '2' INTO var_name.
          LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE2
                    WHERE VNAM = var_name.
          ENDLOOP.
          CONCATENATE 'Please Input Version for Value Type' '2'
                    INTO l_message SEPARATED BY ' '.
          IF LOC_VAR_RANGE2-LOW EQ ''.
          CALL FUNCTION 'RRMS_MESSAGE_HANDLING'
               EXPORTING
                    I_class = 'RSBBS'
                    I_type = 'I'
                    I_number = '000'
                    i_msgv1 = l_message
                    i_msgv2 = l_msgv2 “change
                    i_msgv3 = l_msgv3
               RAISE no_replacement.
          Endif.
     ENDIF.
     ENDLOOP.
     CLEAR l_s_range.
     CLEAR loc_var_range.
     CLEAR loc_var_range2.
     CONCATENATE 'ZS_VTYP' '3' INTO var_name.
     LOOP AT i_t_var_range INTO loc_var_range
               WHERE vnam EQ var_name.
     if loc_var_range-low eq 20 or loc_var_range-low eq 60.
          CONCATENATE 'ZS_VERC' '3' INTO var_name.
          LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE2
                    WHERE VNAM = var_name.
          ENDLOOP.
          CONCATENATE 'Please Input Version for Value Type' '3'
                    INTO l_message SEPARATED BY ' '.
          IF LOC_VAR_RANGE2-LOW EQ ''.
          CALL FUNCTION 'RRMS_MESSAGE_HANDLING'
               EXPORTING
                    I_class = 'RSBBS'
                    I_type = 'I'
                    I_number = '000'
                    i_msgv1 = l_message
                    i_msgv2 = l_msgv2 “change
                    i_msgv3 = l_msgv3
               RAISE no_replacement.
          Endif.
     ENDIF.
     ENDLOOP.
ENDIF.

Similar Messages

  • How to verify the input fileld

    Hi All,
    I have a text field the contents of text field(it should not contailn any thing other then alpah numeric) without using javaScript
    regards
    sankar

    Interesting. What do you want to use? You can use Java if you want to validate on the server side.

  • 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=

  • How to create Variables(User Input Selections) in WEBI Report

    Hi Team,
                  My requirement is to create a WEBI Report on top of BEx query,I have created a Universe and WEBI Report on this Universe but my doubt is How to create Variables for the User to select.The Input selection should be
    User Iputs(All are drop downs)
    Distribution Channel :       ->drop down,user can select one
    Division:                          -> drop down,user can select one
    Department:
    Season:
    Collection:
    Date Format              Valid From:                                 Fiscal Week:
    When the user gives the above selections the output should be displayed as
    Material No   Description     Markdown Week     Reason code1(under this)        Reason code2(under this)   like that for all the
                                                                                valid from         Amount              Valid from          Amount            Reason code.
    I have designed the basic layout of the Report but wanted to know how to design like this,Please help me out in this Format.
    Thanks & Regards,
    Somu

    Hi, depending on the way you set this up (it is not entirely clear if you are talking bex variables or report drop down filters), use the following;
    For BEX variables, the choice will be in the
    UserResponse("prompt message")
    this you can display in the message format you want.
    For drop down filters the choice will be in the DrillFilters(), this one will show all selections in one string.
    However, if you want to format this to a certain message, you need to use the Formula
    DrillFilters([object from drill bar])
    This will give you the result of just that one selection. If the user did not select (yet), the value will be "".
    Hope this helps,
    Marianne

  • How to verify that the variable "does not contain" a value?

    Hi
    I am using CP 7.0.1.237.
    We want to use Text Area widget for a custom quiz and verify an answer. While we figured out how to verify the existence of certain keywords, we are not able to figure out how to verify that the content should NOT contain certain keywords. For example, we want to ensure that the text entered in this widget should not contain "Transformation" and "Non-compliant".
    Is this possible at all?
    Thanks
    Sreekanth

    Here's what the solution might look like in JavaScript.  This would be for SWF output and aimed at Cp 7.  For Cp 8, this would still work for SWF output, but you'd probably want to take advantage of the new unified JS API that gets and sets Cp variables for both SWF and HTML5 output.  You can read more about that here:  Common JS interface
    //Get the text area value from Captivate (SWF output Only)
    var cpTextAreaValue = document.Captivate.cpEIGetValue('m_VarHandle.v_TextArea);
    //convert the value to lower case to properly compare
    cpTextAreaValue = cpTextAreaValue.toLowerCase();
    //Check if text area value contains the words "transformation" or "non-compliant"
    if(cpTextAreaValue.indexof('organizational') > -1 && cpTextAreaValue.indexof('behavioral ') > -1 && cpTextAreaValue.indexof('managerial') > -1 && cpTextAreaValue.indexof('transformation') < 0 && cpTextAreaValue.indexof('non-compliant') < 0){
      //the text area has the correct answer so increment varScore
      //get the current score from Captivate
      var score = document.Captivate.cpEIGetValue('m_VarHandle.varScore');
      //increment score by 1
      score++;
      //set score in Captivate
      document.Captivate.cpEISetValue('m_VarHandle.varScore', score);
    } else {
      //the text area does not have the correct answer so show message to user inside of Captivate
      document.Captivate.cpEISetValue('m_VarHandle.v_message', 'Answer is not correct');
    This JS has not been tested.  Note that the "does not contain" operator is done using the "indexof" operator in JS. 
    Jim Leichliter

  • How to verify input field value at run time

    Hi all,
    I have a input text field (username) on my jsf page and while entring username i have to verify that input provided by me is correct or not.
    For example-
    I started entering Test in username and error message occurs at the same time after validating from db.
    Can any body provide me the code snippet for the same.
    Thanks much,

    Hi,
    If I understood you correctly, you can set autosubmit="true" on af:inputText, and bind valueChangeListener to the method in backing bean where you can check whatever you need to check. That way, when inputText looses focus (or you press enter), the value will be submited to the server, where you can validate it.
    Pedja

  • How get Query Monitor (RSRT1) to show variable input screen

    Hi,
    I'm trying to test a query that has variable input and I can't get the variable input screen to give me a chance to input variables.  Since this is key to debugging this query, I need it to recognize my input variables.
    Help!
    Thanks
    Suzanne

    Hi,
    In rsrt, enter the query name -> select query display as HTML -> In the big text box that appears below it type "variable_screen=x", without quotes and it should show you the variable screen.
    Thanks,
    Sri.

  • How to use variables with

    I need to get the number of lines in internal table, which would
    be easy, using DESCRIBE TABLE itab LINES lines. But the problem
    is, that I get the name of this internal table in the field of
    another internal table, so I have to use the name of internal
    table as variable, but I don't know how to use variables with
    DESCRIBE TABLE (or if this is possible).

    Hi,
    REPORT ZPRUEBA782 .
    define two tables with diferent structures.
    data: begin of table1 occurs 0,
    registro type i,
    end of table1.
    data: begin of table2 occurs 0,
    registro type i,
    repid like sy-repid,
    end of table2.
    data: rows type i.
    start-of-selection.
    fill them with data
    do 1000 times.
    table1-registro = sy-tabix.
    append table1.
    enddo.
    do 1757 times.
    table2-registro = sy-tabix.
    table2-repid = sy-repid.
    append table2.
    enddo.
    call a form that receives as input the table and returns the number
    of rows as output.
    perform howmanyrows tables table2 changing rows.
    break-point. "evaluate the number of rows
    perform howmanyrows tables table1 changing rows.
    break-point. "evaluate the number of rows
    end-of-selection.
    form howmanyrows tables itable changing rows.
    rows = 0.
    loop at itable.
    add 1 to rows.
    endloop.
    endform.
    You can try it if you don't find a better solution.
    Cheers,
    Chaitanya.

  • How to Read Variable Values in WAD 7.0 Using JavaScript

    I found a how to: How to Read Variable Values in WAD 7.0 Using JavaScript on SDN.
    I get a Javascript error:
    bics.getElementsByTagName is not a function
    vars = bics.getElementsByTagName("VARIABLES")[0]; // <VARIABLES>
    Thats my script:
    function currency()
    var varnm = "SFS_CP_CURR"; // Name of the variable to be read
    root = document.childNodes[0]; // <HTML>
    body = root.getElementsByTagName("BODY")[0]; // <BODY>
    xml = body.getElementsByTagName("XML")[0]; // <XML>
    bics = xml.childNodes[0]; // <BICS_VIEW>
    vars = bics.getElementsByTagName("VARIABLES")[0]; // <VARIABLES>
    varl = vars.getElementsByTagName("VARIABLE"); // gives no. of variable in DP
    for ( i = 0; i <= varl.length; i++ ) // Loop one by one
    vari = vars.getElementsByTagName("VARIABLE")<i>;
    varnam = vari.attributes[0].text; // get variable name
    mem = vari.getElementsByTagName("MEMBER")[0];
    varval = mem.attributes.getNamedItem("name").value; // read variable value
    if (varnam == varnm) //check varname in loop needs to be read
    if (varval == "ZMON") // check for value1 and fire command1
    SFS_CP_M();
    if (varval == "ZKON") // check for value2 and fire command2
    SFS_CP_K();
    break;
    Where's the mistake?

    I'm afraid I haven't made my question understood clearly.
    What I am looking for is a method to get the value of variable inside excel (e.g. put it into a cell / range of a worksheet, so that we can reference it and use it as an input for planning function execution).
    Please advice.
    Thanks in advance,
    Shady

  • How to verify JavaScript alert message display on page with C#?

    Hi All,
    I have a question about verify the JavaScript alert message on page. For example, I input the script in browser address like: "javascript:onmouseover=alert('popup windows')" . How to verify there's a alert message displayed on page with C#?
    Thanks

    Are you trying to use some automation or ? What the previous solution is they have put the text in the dom for you to pull out with C# or other languages.
    if you are trying to automate this through a browser maybe look into WebDriver
    WebDriverWait wait = new WebDriverWait(driver, 2);
    wait.until(ExpectedConditions.alertIsPresent());
    Alert alert = driver.switchTo().alert(); var alertText = alert.Text;
    alert.accept();

  • How to include variable in the text column in report painter?

    Dear Expert,
    Would like to seek for your help to include How to include variable in the text column in report painter?Please advice.
    Thank you.
    Regards,
    Karen
    Edited by: Karen Swee Ping Ho on Jun 17, 2011 2:48 AM

    Hi,
    Thank you for the promt reply.
    1) How I include the variable in the column header to display fiscal year which I have selected from the selection screen?
    which variable should i use?
    2) Where can i find more information about the characteristic and which variable to be use base on the characteristic?
    For example: I would like to display the fiscal year from the selection screen/input screen when execute the report which also will reflected to the element definition and will display the fiscal year also in the column text?
    3) Kindly advise base on question 2, the variable that i use in element definition it will also display  in selection screen?
    4) When execute the report the first selection screen input parameter it obtain from where it is from element definition?
    5) Please advice how to be done when report execute with first screen input selection will also reflect the element definition of column and rom with the selection of the fiscal year?
    Please help.
    many thanks
    Edited by: KH on Jun 18, 2011 7:18 AM

  • Variable input in Webi Report

    Hello Experts,
    I have a requirement to create a Webi report which has 3 key figure columns.
    While executing report It should ask for input variable fiscal year/period.
    Now 1st key figure colum should show Amount for the fiscal year/period I entered as an input variable.
    2nd column should show Amount for previous YTD for the fiscal year I entered.
    For Ex. if I enter 04.2009 it should show amount for 01.2009 - 04.2009 and if I enter 04.2008 then it should show amount for 01.2008-04.2008.(based on the variable input I provide)
    3rd column should provide the Amount <= ficsal period I enter as an input.
    Can anyone guide how would I achieve this?
    Regards,
    Nirav Shah

    Hi Nirav,
    what is the granularity of the time dimension of your data in your report? Generally you make sure that you fetch all required in your report and then use formulas (applying the if operator on the time field of your data and the value returned from your prompt) to calculate the desired key figures.
    Regards,
    Stratos

  • Dynamic field selection by variable input in bex report

    Hi Frineds,
              I have created  variable on characteristic  ( 0CURTYPE )  which mainly have two values 'A' and ' B' .Based on my variable input in Bex I have to dynamical select key figuers  Example .
    0CURTYPE    KeyfigA  KeyFigB  
    A                    123 Rs   144 $
    B                     124 Rs   145 $
            In above example is user select A I have to display KeyfigA   if I select B then i should display Keyfig B in Bex report .
    I know that by using user exit in report we can do but I would like to try with out Exit .
    Thanks ,
    Kumar.

    Your formula variable allowed to be of type either number or amount or date or quantity which are all numeric(currency type/type tab) .But your reference characteristics is a letter.So there is an inconsistency here and you can not make equal your formula variable and 0currtype's variable.
    Have a look at Akshata's post in this thread :How to create formula variables in sap bi?
    Therefore this model does not work and I can not see any other way apart from a very simple user exit which says if 0currype=A, then formula variable=0 else if 0currtype=B then formula variable=1.After that you can use your formula variable in your formula since the letters are now converted to numbers.
    By the way it mustn't ask two things in the selection screen.Since your formula variable takes the values of 0currtype's variable automatically.Did you create the formula variable with replacement path(general tab) referencing to 0currtype?Just create a formula, enter this formula,right click create formula variable,go to general tab then replacement path then reference to 0currtype.But as I told, you nevertheless can not achieve it, just explaining it.
    Regards,
    Sunny

  • How to set variables values via VBA.

    Anybody please help.
    How to set variables values via VBA in workbook. SAP Netweaver 2004s.

    Pass variable values with VBA and BI 7.0 funtions to Query
    At first a remark u2013 Iu2019ve read a lot of threads saying that passing values to a query can be done by using VBA code only. Iu2019ve tested it but Iu2019m not sufficient with the new BEX 7.0 API and therefore I use a mixture of BEX 7.0 funtionality and VBA. I create a BEX 7.0 design item button passing the values to a query u2013 I hide this button somewhere on the sheet or on a hidden sheet and I then raise the event to click the button from VBA code. Works fine and the maintenance is easier if something changes in the API in the future again.
    How to start:
    Switch to design mode in BEX Analyzer:
    Implement a BEX 7.0 design item u201Cbuttonu201D
    Click on the button to implement the properties
    Make the input for the commands
    data_provider = dataprovider_1
    cmd = process_variables
    subcmd = var_submit
    No comes the part with the variables u2013 Letu2019s assume a query has 4 variables but you only want to change 1 with the button u2013 an organizational unit for instance.
    Make a range somewhere in the excel with the following structure:
    Name    Index   Value
    VAR_NAME_1      1       Variablename
    VAR_VALUE_EXT_1 1       variablevalue
    Value should contain the name of your variable of course and u201Cvalueu201D the value of your variable
    Set a name for this range with EXCEL functionality but without the header:
    Back to the properties of the button: Insert the name of the range with the variables in the field Command Range:
    If you have more variables to process you can of course enhance your Filterrange!
    In the left upper Corner you have a name for your button:
    Now you can raise the button-click in vba like this:
    Application.Run "'" & ThisWorkbook.Name & "'!Sheet2.BUTTON_35_Click"
    regards, Lars

  • Variable input values in the query are displayed wrong

    Hi experts,
    I executed a report and in the variable input screen it asks for a key date and company code.
    We entered key date and company code and executed the report.
    We want to take a print out of the output. But the variables which we entered in the variable screens are
    dispalying wrong. i.e if we have entered company code as gsml and key date as 01.01.2008.
    In the report output I am getting as:
    Company code: gsml
    Keydate: #..27-11-4745
    But keydate should be displayed as 01.01.2008
    How to solve this ?
    Regards,
    Nishuv.

    Nishuv,
    Please follow below steps:
    1. Open query through Bex - Query Designer
    2. Beneath the Rows Area( where you actually  drag in charactertistics), you'll be finding two tabs Filter and Rows/Columns
    3. Click on Filter Tab
    4.You'll be navigated to a window, there you can trace two Workareas
            a. Characteristic Restrictions: Where drag in the relevant Prompts/Input Variables
            b. Default Vaules
    5.First, Drag the required promts/Input Variables in Characteristics Restrictions.
    6.Click on the varible which was dragged in Characteristic Restriction area and drop it into default values area.
    7.Now you'll have visibility of variable in two regions, Characteristics and Default Values.
    8. Save and Execute the Query
    Regards,
    Yaseen

Maybe you are looking for