cancel
Showing results for 
Search instead for 
Did you mean: 

Used DC not showing up

Former Member
0 Kudos

Hi,

I have two DCs DC1 and DC2. DC1 is a main application and DC2 is for Search functionality. I could add DC2 in DC1 and call the search screen. Now on Search screen when i click back, i want to come back to DC1. for this i have added DC1 as used dc in DC2. But when i click on the "embed used DC" in the modeler i am not able to find the DC1 in the selection list. Can anyone pls let me know how to solve this. How can i navigate back to my main screen?

Pls let me know.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Aditya,

Cyclic dependencies are not allowed in WebDynpro !!

Regards, Anilkumar

Former Member
0 Kudos

Are you saying that i am not able to add DC1 in DC2 as a used DC because i have already added DC2 as usedDC in DC1?

But in such case what could be the solution for this. I have a DC for search fucntionality. For any other DC to use this search functionality it should declare a dependency for this Search DC. And for coming "Back" to the original application from this Search DC i should again declare the main DCs as used DC in the Search. This is obviously a cyclic dependency. And if this is not allowed what is the other way of achieving this?

Please suggest.

siarhei_pisarenka3
Active Contributor
0 Kudos

Hi Aditya

The cycle can be avoided as I writed before by throwing WD event or firing Exit navigation plug from Search DC. In the case the back reference from Search DC to main DC is not required. Search DC just throws event or fire Exit plug without thinking who will handle the event or plug in reality.

Best Regards

Sergei

Former Member
0 Kudos

But in the Eventing example, they are still adding the Internal Component as used Webdynpro component. This is exactly what i am not able to do. I mean it shows the entry for DC1's public part under the usedDCs node of the DC2. But when i go to the modeler and "Browse" i am not getting to see this DC1s Component.

Appreciate your help. Please suggest.

I tried all the options in the context menu. Build, rebuild, reload, repair, DC->Refresh, DC->Build etc. but no use.

Message was edited by: Aditya Atluri

siarhei_pisarenka3
Active Contributor
0 Kudos

Aditya

Try to be more specific... Structure of your DCs will be the following:

1. Search DC (DC2):

- has public part with the WD component;

- interface view controller declares the event;

- when user clicks Back button the WD component throws the event;

- no any references to DC1 in Used Components or Used DCs;

2. Main DC (DC1):

- has reference to public part of Search DC in Used DCs;

- has reference to Search component in Used components;

- custom controller declares event handler for the event of Search DC;

- the event handler shows Main view as its body (by firing plug to Main view from, for example, some third empty view);

BR

Sergei

Former Member
0 Kudos

Sergei,

Appreciate your help.

I have not come to the eventing part yet. As of now,

1) Search DC (DC2)

- Has Public Part with its WD Component

- Has reference to public part of Main DC in used DC

- NO ref to Main Component in used Components. This is not working. The Main Component is not showing up in Diagram View->Used Webdynpro Component Or SearchComponent->Used webdypro component->Add. As per my understanding i should some how make the Main DC component visible over here. Only then i will be able to fire the events or plugs. Once this is done i feel i should be able achieve the "Back" functionality by Firing WDEvent or Firing outbound plug. Please correct me if i am wrong.

2) Main DC (DC1)

- Has Public part with its WD Component

- Has reference to Public part of Search DC in used DC

- Has ref to Search Component in used components

- Created outbound plug from the View in Main DC to View in Search DC. When i click on Search it goes to Search View in Search DC as required.

Please suggest.

siarhei_pisarenka3
Active Contributor
0 Kudos

> - NO ref to Main Component in used Components.

> nts. This is not working. The Main Component is not

> showing up in Diagram View->Used Webdynpro Component

> Or SearchComponent->Used webdypro component->Add. As

> per my understanding i should some how make the Main

> DC component visible over here. Only then i will be

> able to fire the events or plugs. Once this is done i

> feel i should be able achieve the "Back"

> functionality by Firing WDEvent or Firing outbound

> plug. Please correct me if i am wrong.

Actually you CAN fire events or exit plugs here without the reference, because the event or plug is a part of the component, not a part of Main component. I mean the event or exit plug must be declared in the interface view controller of the component.

>

> 2) Main DC (DC1)

> - Has Public part with its WD Component

> - Has reference to Public part of Search DC in

> C in used DC

> - Has ref to Search Component in used components

> - Created outbound plug from the View in Main DC

> n DC to View in Search DC. When i click on Search it

> goes to Search View in Search DC as required.

In case of event - create event handler here and fire plug to Main View from some third view of the component;

In case of exit plug - join the exit plug from Search Comp with input plug of Main View;

BR

Sergei

Former Member
0 Kudos

Sergei,

Thanks. Will try this and let you know.

Answers (2)

Answers (2)

siarhei_pisarenka3
Active Contributor
0 Kudos

Hello Aditya

I think is not good idea to make cross reference between the two DCs because at time of building a compiler could not find what to build at first DC1 or DC2.

Instead of it I guess you may make the return from Search screen, for example, by throwing WD event from Search screen and handling the event in DC1. I mean that DC2 would throw event when user clicks Back button. DC1 would handle the event and make navigation to main screen.

Another solution may be to fire exit plug in DC2 when user clicks Back button. DC1 must join the exit plug into some input plug one the main screen.

Best Regards

Sergei

MG3
Contributor
0 Kudos

Hi Aditya

Once you have declared the component as Public part in DC1 and added this to the Used DC in DC2, build it - right click project under webdynpro perspective > Development Component > Build...

Then try adding the used webdynpro component in the diagram view of DC2. it should work.

Please refer this for navigation:

<a href="https://www.sdn.sap.comhttp://www.sdn.sap.comhttp://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/a137c339-0b01-0010-a688-a87b88706845">Cross Component Navigation</a>

regards,

oj

Former Member
0 Kudos

Manoj: Actually i am facing the problem with Build itself. Once i click on Build it just goes away in a fraction of seconds. Because of this i am thinking it is not builiding it properly and hence i am not able to see the DC1 as used DC in DC2.

I think i should look into why it is not building properly.

Siarhei: Could you pls send me a document on this WDEvents?

Thank you all for your help.

Message was edited by: Aditya Atluri

siarhei_pisarenka3
Active Contributor
0 Kudos

Hi Aditya

Here is the tutorial about WD events:

<a href="http://help.sap.com/saphelp_nw2004s/helpdata/en/24/243ca46e1c334f8a6f8b0792656bc7/content.htm">http://help.sap.com/saphelp_nw2004s/helpdata/en/24/243ca46e1c334f8a6f8b0792656bc7/content.htm</a>

You need to declare Event in Interface View Controller of DC2 and fire it when user clicks Back button. In DC1 you need to subscribe your custom controller or component controller to the event and handle it.

Best Regards

Sergei