Skip to Content
avatar image
Former Member

How to display response from webservice in second view?

Hello,

I would like to develop an application which should do a webservice request from one view and displays the result on another view. How can I do this? Is there an example how to do this?

Thanks in advance.

Kind regards,

Carsten

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

1 Answer

  • avatar image
    Former Member
    Jul 01, 2004 at 03:58 PM

    Hi Carsten,

    let view VA be the requesting view, VB the view to display the response and RCC a custom controller which is used for actually performing the request and "owns" the Web Service model, then you need the following:

    1. VA has a context node with attributes mapped to the request-attributes of the model. If necessary, some UI elements may be bound to these request attributes. For triggering a request, there's an additional button.

    2. VB has a context node mapped to the response/result node of the WS model. There could be a table bound to the node in case of multiple possible results.

    3. RCC imports the Web Service model and acts as the service controller (you can use Apply template->Service controller to achieve that) and provides a method "executeXXX" to call the Web Service.

    If the button in VA is pressed, executeXXX is invoked, the service is called using the current contents of the request attributes of the model, results are stored in the response/result node. Invalidating the node will display the result(s) in VB.

    Hope that helps.

    Regards

    Stefan

    Add comment
    10|10000 characters needed characters exceeded