Dynamically calculate the value

Dear all,
Hope you are well.
i am in need a feature in OAF pages.
suppose i have fields like advance_amount,total_amount,return_amount,amount_to_be_taken
when employee log in this page advance_amount will automatically loaded and based on input of total_amount other
fields amount will be calculated and shown dynamically.
how can i activate this feature.
please suggest.

Hi,
Here is the code:
CO PFR:
public void processFormRequest(OAPageContext pageContext, OAWebBean webBean)
super.processFormRequest(pageContext, webBean);
if("TextinputEvent".equals(pageContext.getParameter(EVENT_PARAM)))
if(pageContext.getParameter("TextInputID")!=null)
String Text1=pageContext.getParameter("TextInputID").toString();
---Do the calucaltion and fetch into String Text2...
String Text2=Text1;
OAMessageStyledTextBean Bean=(OAMessageStyledTextBean)webBean.findChildRecursive("Text2");
Bean.setValue(pageContext,Text2);
Regards
Meher Irk

Similar Messages

  • Dynamically setting the values for the Adapter Configuration in BPEL

    We are configuring the JMS adapter to put into an MQ topic. For this we are giving all the values for the configuration parameters like
    Factory Properties.
    JMS connection Factory
    Transacted
    Destination Type
    Username
    Password
    Destination Name, etc...
    and we are able to produce message on the MQ.
    Our requirement is to dynamically pass the values for the above parameters from some configuraion files(other than oc4j-ra.xml), which will have value for each obove parameters.
    Any help on this is highly appreciated.
    Regards,
    Suman

    Re: JMS Properties setup
    this thread will explain how to do it.

  • Dynamically setting the values for the Adapter Configuration

    We are configuring the JMS adapter to put into an MQ topic. For this we are giving all the values for the configuration parameters like
    Factory Properties.
    JMS connection Factory
    Transacted
    Destination Type
    Username
    Password
    Destination Name, etc...
    and we are able to produce message on the MQ.
    Our requirement to dynamically pass the values for the above parameters from some configuraion files(other that oc4j-ra.xml), which will have value for each obove parameters
    Any help on this is highly appreciated.

    Re: JMS Properties setup
    this thread will explain how to do it.

  • Forming a report query dynamically with the value of an item

    Hi Gurus,
    We wanted to create a report based on the value of an item in the page.
    For example
    There is a text box named p1_table depending on the value of this item the query of the report should change
    1) when p1_table = emp then report query should be select * from emp
    2) when p1_table = dept then report query should be select * from dept
    I tried doing this using
    select * from :p1_table and select * from v('p1_table') , it is not working.
    Kindly help me in achieving the requirement.
    Thanks & Regards,
    Vikas Krishna

    Hi Vikas,
    You have to do this as a report based on a function that returns the query as a string. You build up the string dynamically in the function.
    Regards
    Andre

  • Dynamically change the value in order by clause (urgent)

    Could any one help atall with this.
    I have a cursor within a procedure and i want to be able to pass parameter into the procedure so that the record fetched by the cursor can be ordered by the parameter passed in.
    For instance
    create or replace procedure select_all(p_order_by in varchar2) is
    cursor r_cur (c_order_by in varchar2) is
    select empno,empname,job,manager,salary
    from emp
    ordry by c_order_by;
    r_rec r_cur%rowtype;
    lv_order_by varchar2(30);
    begin
    lv_order_by := p_order_by;
    for r_rec in r_cur(lv_order_by) loop
    dbms_output.put_line(empno||empname||job||manager||salary);
    end loop;
    end;
    I have obviously done it as written above but the output is not ordered by the value i passed into the procedure when ran. Is the a better way to achieve the desired result?

    I handle dynamic order by using dynamic sql
    create or replace procedure select_all
                   (p_order_by  in varchar2) is
    TYPE               RefCurTyp is REF CURSOR;
    CV                    REFCURTYP;
    v_sql_stmt  VARCHAR2(4000) ;
    r_rec r_cur%rowtype;
    BEGIN
      v_sql_stmt := 'select empno,empname,job,manager,salary '||
                                ' from emp ' ||
                                ' ORDER BY '||p_order_by ;
      open CV for v_sql_stmt;
      loop
            fetch CV into r_rec ;
                    exit when CV%NotFound;
            dbms_output.put_line(r_rec.empno||' '||r_rec.empname||' '||r_rec.job||' '||r_rec.manager||' '||r_rec.salary);
      end loop;
    close CV;
    end;

  • How can I calculate the value of the cell, which depends on other rows?

    Hi, all!
    I have an application with table. In this table i have calculate some fields, that doesn't exists in data class and depends on other row values, e.g. current row number, or sum of previous rows. How can i calculate this values in TableView?
    The problem is that I have no information about the current row number in the cell value factory.
    Example:
    public class Transaction {
         public String getName();
         public BigInteger getAmount();
    } // There is no getter for "Balance"
    Result table should be something like this:
    Name
    Amount
    Balance
    transaction1
    300
    300
    transaction2
    200
    500
    transaction3
    500
    1000
    Also, after sorting by "Amount", "Balance" should be recalculated:
    Name
    Amount
    Balance
    transaction3
    500
    500
    transaction1
    300
    800
    transaction2
    200
    1000

    Strings can be converted to numbers by various parse methods. For instance Strings can be converted to double via Double.parseDouble(myString).
    That being said, it appears that your textfield will contain numbers and operators, and so these operators will need to be parsed too. I would advise you to search on the terms Java infix postfix.

  • How to calculate the values

    Hi Experts,
    I have doubt, i have an internal table now i want to calculate the total for every group. How to do that?
    value          type
    5,439.01 ;    ZMP0
      509.60 ;     ZMP0
    4,749.26 ;    ZMP0
    9,053.95-    ZPNL
    732.70-      ZPNL
    66.30-       ZPNL
    18.10-        ZS03
    63.90 ;        ZS03
    According to the type i need a total for ZMPO, ZPNL, ZSO3 separately.
    how to do that?
                       5,439.01 ;    ZMP0
                         509.60 ;     ZMP0
                        4,749.26 ;    ZMP0
    ZMPO total =
                         9,053.95-    ZPNL
                          732.70-      ZPNL
                           66.30-       ZPNL
    ZPNL total =
                          18.10-        ZS03
                           63.90 ;        ZS03
    ZSO3 total =
    Like that i need, can any one help this?
    Regards,
    Mohana

    Hello,
    Use the COLLECT.
    DATA:
      wa LIKE LINE OF itab,
      itab_sum LIKE itab.
    SORT itab BY key.
    LOOP AT itab INTO wa.
      COLLECT wa INTO itab_sum.
    ENDLOOP.
    The itab_sum has the same structure like the itab where is the data to me summarized, and the wa has the line structure of the itab.
    Regards.

  • Dynamically change the value in standard text

    Hi all,
      I have created standard text using SO10  transaction. I have included the text id in SAP FORM. My requirement is some text need to change dynamically in the text  when printing the form.Is there any way to do it.
    Thanks
    Suadrsana

    Hi .. Here is the solution ...
    Hi &V_NAME&
    Thanks
    XXXXXXXX
    U need to get the value of
    V_NAME
    from the SF.
    If u have the value of the variable in an internal table, then
    LOOP AT ITAB INTO WA.
      V_NAME = WA-NAME.
    ENDLOOP.
    I think this will be useful.
    Suhas
    Message was edited by:
            Suhas Saha

  • Column dynamically calculates the records entered

    Hi all,
    anyone could pls help with placing a column in oaf creates page which calculates the no of records entered and updated automatically.

    Ok,
    There are couple of ways in which you can achieve this. The one i can think of right now is,
    Create a transaction variable when the page loads and name it as v_count. When ever a row is updated, increase the count of this variable. Once the page is submitted, release the transaction variable value.
    So as long as the page is active, you can keep track of the value in that variable v_count .
    Regards
    Pavan , K

  • Dynamically changing the value in table control

    Hello Every one,
    In MD61 transaction table control am trying to change value dynamicaly i.e am trying to change value in table control automaticaly tht value to be captured and i need to show in status bar...
    Ex table control field is number: am giving 10,20,30 tht should show in status bar by adding if u enter 10 at status bar it show 10 then when u enter 20 it should add with 10 and give 30 ..
    in this way when ever u enter value in filed it should add with the status bar value.

    Hi!
    For conversion you can use the function module
    data :   w_amt         TYPE cms_dte_original_amt,
                                                                                    " Amount
                w_conv_amt    TYPE cms_dte_conv_amt,
                                                                                    " Converted amount
                w_kmein       TYPE cms_dte_original_curr,
       CALL FUNCTION 'CMS_API_CURR_CONV'
            EXPORTING
              i_original_curr = w_kmein
              i_original_amt  = w_amt
              i_result_curr   = 'INR'
              i_rate_type     = 'M'
              i_conv_date     = sy-datum
            IMPORTING
              e_conv_amt      = w_conv_amt.
    now accordingly you can move the currency and amount that is changed....
    here as you were saying that on f4 after selecting you want the other field to get the value on that currency.....
    this work can be done as here....
    in this the next field gets populated as the first field gets the value......
    refer to it.....
    https://wiki.sdn.sap.com/wiki/display/ABAP/GettingainputfieldpopulatedonenteringthevalueinoneInputfield
    Regards.

  • Dynamically passing the values to search help

    hi
    can I pass some values dynamically to search help input field.
    If I select a profit centre value from a drop down in separate field it should reflect the corresponding values in
    search help which is cost centre input field ( i/p fields is in a column of a UI element table).
    If I add one more row also the corresponding column should bears the search help...
    thanx in advance.......

    Data dictionary based search helps can have multiple importing parameters within Web Dynpro.  There are few rules that are documented in the online help however:
    Be aware that import and export parameters for the search help are determined only within the same context node (see also Transport of Values for the Input Help), and even then only if a Dictionary structure is assigned to the node.
    http://help.sap.com/saphelp_nw70/helpdata/EN/35/bdb6e2c48411d1950800a0c929b3c3/frameset.htm

  • Dynamically passing the values to IN query in JDBC

    Hi,
    I have a list which contains a single or multiple values which does have CustomerVO as a generic.Here i need to iterate the list pass these values to "IN" query.
    These should happen dynamically, as we dont know whether the list will hold a single or multiple value. If the list.size ==1 , then it contains a single value in it. Hence there is no need for a comma(,) in the IN query else we need to have it, like .... IN (Aaron,Bob). Please help me in this?
    Thanks.

    797836 wrote:
    I have a list which contains a single or multiple values which does have CustomerVO as a generic.Here i need to iterate the list pass these values to "IN" query.
    These should happen dynamically, as we dont know whether the list will hold a single or multiple value. If the list.size ==1 , then it contains a single value in it. Hence there is no need for a comma(,) in the IN query else we need to have it, like .... IN (Aaron,Bob).So basically you need to output the List (capital 'L') as a comma-delimited list (small 'l').
    The procedure for that is usually something like:
    1. Output the first element.
    2. For any further elements:
    2a. Output ","
    2b. Output the element.
    Winston

  • Dynamically insert the values in mysql

    hi am using flex with java i want to insert the text field  values dynamically into mysql database
    plz can anyone let me know how to do this
    thanks in advance
    sonu

    Hi,
              Pass the information from flex to java using httpService or using data Services and from there insert to DataBase.
              http://coenraets.org/testdrive/flex4j/index.htm

  • How to calculate the value of key figure by considering other char or kf

    Hi
    My requirement is like this:
    I have a key figure which gives me the planned issues and receipts but i know that if only from locaton is blank  and to loc is filled then that are receipts and if both the from and to location values are filled then it is issues,
    can you pls let me know how i 'll put this logic in th reporting bex and how i achieve this by user exit or any other way
    thx
    rubane

    Create two RKF, restrict first with [ from = '#' ] to get the planned receipts, and restrict the second with [ from <> '#' and to <> '#' ] to get the issues.

  • How can i  calculate the values of the chars in a string

    yeah, what was the method for that?

    Do you mean that you want the numeric values for characters within a String?
    You could do something like this:     String s="This is a test";
         int val[]=new int[s.length()];
         for (int i=0; i<s.length(); i++) {
              val=(int)s.charAt(i);
    Mark

Maybe you are looking for

  • Key mapping in SSH

    Background info: There are some users here that use Secure Netterm to log into an IBM server and do some telnet stuff (transactions etc.). There are a few users that need to use that but use Macs. Secure netterm does not work in Virtual PC so we are

  • Inter iView Connectivity : MDM SP4

    Hi, I'm working with EP Business Package for MDM SP4. The requirement is to integrate the functionality of MDM iViews with Web Dynpro iViews. This can be done through client side eventing ( EPCF ) and I read in MDM SP4 feature list that, this connect

  • VPN Connection Established but now cannot access the internet

    I am running Mac OS X 10.4 and have successfully downloaded Cisco VPN Client version 4.9.01.0080. Although I can successfully establish a connection, I am no longer able to connect to the internet - my internet connection can only be regained if I di

  • Mscorsvw error message when trying to run Exchange 2013 CU 8

    I'm getting this error when trying to run CU 8 on our Exchange 2013 server. How to make it not happen?? Is there any way to find out how/where this process is running so it can be closed?? Thank you, Tom

  • Can't boot VM with Xen PVM

    I downloaded Oracle Enterprise Linux 6 U3 VM template(OVM_OL6U3_x86_64_PVM.ova) from eDelivery Oracle. Imported to VM Template and created Virtual Machine. I gave one Physical Disk, and only 'Disk' on Boot Order. When I start VM, I got following erro