cancel
Showing results for 
Search instead for 
Did you mean: 

Navigation between WebDynpro Components

Former Member
0 Kudos

Hello,

maybe this has been asked before, but i do not understand how to get back from component B to component A.

I have created several components in one application. One component is needed as starting point of my application (lets say component A). From component A i can get via LinkToAction to component B, because i added an interface controller of component B.

Because of cyclic errors, i can't do this to get back from component B to component A.

Is there a way to get this done?

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Christian,

you can try the following:

From the interface view controller use the interface controller and from thereon send an event to some controllers which should react on the inbound plug.

On the way back use the view controller which should handle the action to the component outbound plug. In this view make a usage of the interface view controller. Then you have the possibility to fire the outbound plug in the view controller in the way: wdThis.wdGet<interfaceviewcontroller>.wdFirePlug<outboundplugname>

Best regards,

Christian

Former Member
0 Kudos

Hi Christian,

i have done the following:

created two components FirtsView and SecondView. I can navigate from FirstView to SecondView!

to get back:

SecondView:

- created an innerEvent in the InterfaceController

- created an Action called from a link that calls the innerEvent

FirstView:

- created an EventHandler in the View Controller

- added required Controllers (FirstInterfaceView, SecondInterfaceController)

- created OutboundPlug in FirstInterfaceView

- fire plug in EventHandler method

Maybe here is already an error, but what is the outboundplug good for??? I can't see what it is usefull for?

Best regards,

Christian

Former Member
0 Kudos

Hi Christian,

one possible solution for your current scenario is (A = FirstComponent, B = SecondComponent):

1. The Interface View of A has an Outboundplug ToB and an Inboundplug FromB.

2. The Interface View of B has an Inboundplug FromA and an Outboundplug ToA.

3. The plugs ToB->FromA and ToA->FromB are connected by links in the navigation modeler.

4. The Interface Controllers of A and B subscribe as event listeners to the following events of Component Controllers of A and B.

5. Component Controller A has an event toNext, Component Controller B toPrev.

6. Views of A and B use their Component Controllers to fire the corresponding event (Next/Prev). The events are fired in action handlers. It's not nice IMO, that the views use their enclosing components, but there's no other chance.

7. The Interface Controllers of A and B use the Interface View Controllers to fire the plug(s).

So,

the Views use the Component Controllers.

the Interface Controllers use the Component Controllers.

the Interface Controllers use the Interface View Controllers,

but none of these usages is cyclic.

Hope that helps.

Regards

Stefan

Former Member
0 Kudos

Hi Christian,

could you please describe your scenario again. Maybe I misunderstood you.

What do you mean with get back? Navigate back or send events back?

Are your both view displayed concurrently at the same time or does SecondView overlay FirstView and you want to navigate between them both?

Or do you just need to instantiate component SecondView and use eventing between them both for sending some message/payload?

Best regards,

Christian

Former Member
0 Kudos

Hi Christian,

could you please describe your scenario again. Maybe I misunderstood you.

What do you mean with get back? Navigate back or send events back?

Are your both view displayed concurrently at the same time or does SecondView overlay FirstView and you want to navigate between them both?

Or do you just need to instantiate component SecondView and use eventing between them both for sending some message/payload?

Best regards,

Christian

Former Member
0 Kudos

Hi Christian,

could you please describe your scenario again. Maybe I misunderstood you.

What do you mean with get back? Navigate back or send events back?

Are your both view displayed concurrently at the same time or does SecondView overlay FirstView and you want to navigate between them both?

Or do you just need to instantiate component SecondView and use eventing between them both for sending some message/payload?

Best regards,

Christian

Former Member
0 Kudos

Hello,

sorry, that i am answering that late! I thank you for you support! I finally made it with the following configuration: (hope this is clear)

Navigation Project:

FirstView

View Controller -> Inbound- / OutboundPlug

Used WebDynpro Component -> Second Interface Controller

View -> Required Controller -> Second InterfaceView

Navigation -> Action ( firePlug directly)

Second View

Interface View Controller -> Inbound- / OutboundPlug

View -> Required Controller -> Second InterfaceView

Navigation -> Action ( fire Plug programatically wdThis.wdGetSecondInterfaceViewController().wdFireToFirst())

Thanks again!

Christian

Answers (0)