Skip to Content
avatar image
Former Member

BAPI Data not Refreshing/re-populating for different input parameter

Hi WD for Java Exprets,

I have a specific requirement . I am able to display results in a seperate/second View after executing BAPI by passing input parameter in first view. But I have problems with executing the for different input parameter by navigating back to first view from second/result view.

When I execute BAPI with input parameter from the first view, the result displyes are correct for the first time.From them same data is comping for any user.

I am also looks for ways how to clear the node data from the context so that BAPI would get the new result based on input parameter passed

Can some one help me how to solve this problem?. I promise to award points for right answers.

Regards

Maruti CR

chandra-s@mailcity.com

Message was edited by:

Maruti cr

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

3 Answers

  • Best Answer
    avatar image
    Former Member
    Sep 07, 2007 at 04:36 AM

    Hi Maruti,

    Its a better practise to invalidate all the nodes under output node just after executing the model .If u apply template to component controller,the execute method is automatically generated & code for execute model as well as invalidate code also gets generated.

    regards

    Sumit

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Sep 06, 2007 at 06:50 PM

    Hi Maruti,

    In second view's modifyview method you will get a boolean value <b>firstTime</b> through that you can do it. The value will be there in node itself

    after executing the BAPI. But it will not reflect so you have to populate through modifyview method only.

    for example

    if(firstTime)

    {


    your code

    }

    regards

    Sukanta

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Sep 07, 2007 at 03:47 AM

    Hi,

    To get the refreshed data every time for your inputs just invalidate the output model node.

    Assume your output node name is output

    wdContext.nodeOutput().invalidate();

    I assume that you are executing your BAPI in the first view itself and just below that write this line to invalidate the output node.

    Hope now the changes would be reflected in your second veiw.

    Regards,

    Murtuza

    Add comment
    10|10000 characters needed characters exceeded