Fire outbound plug from view in a DC to the interface view.

I have a DC1 which has a view.From this View I fire a outbound plug with a string parameter to an interface View's inboundplug with the string parameter.This view is in another DC2 and used DC in DC1.
Now when I try to Build the DC1,I get build error with the error log saying that the plug parameters arent compatible.But both the parameters are of same type.

Hallo Kent,
as long as your Comp A component keeps alive it also keeps it state when leaving it via navigation. By setting its lifecycle property as "manual" you can manage the lifecycly of Comp A on your own. This means the Web Dynpro Java Runtime will not destroy this component instance when leaving it via navigation.
To navigate back you can apply the cross-component navigation technique I described within my tutorial on https://www.sdn.sap.com/irj/sdn/downloaditem?rid=/webcontent/uuid/751d003a-0b01-0010-8996-afbaa3fd5339">cross-component [original link is broken] [original link is broken].
Regards, Bertram

Similar Messages

  • Fire window plug from another component

    Hi,
    I want to fire a plug which is created in the window of one component, from the view of a different component.
    Is this possible?
    Any information would be much appreciated.
    Thank you!

    Hi Christian,
    thank you for the tip.
    But if I do this in that way then I get a new strange problem:
    I have a main component and two sub-components A and B. The views from component A and B  are embedded in a view container of the main component. So either component A or component B is displayed in the main view.
    Now I fire the outbound plug in A (which is connected to the inbound plug of the main window).The main windows inbound plug handler fires the corresponding outbound plug connected to the view of component B.
    Now the strange behavior is the main view will be displayed twiced. The second one is included in the first one.
    Starting view:
    | main view
    |  __________
    |  | view A
    |  __________
    After firing the plug:
    | main view
    |  __________
    |  | main view
    |  |  ________
    |  |  | view B
    |  |  ________
    |  __________
    Regards
    Thorsten

  • Fire Outbound-Plug of Window in Componentcontroller

    Hello,
    i have defined a Component Interface Definition with an Interface-View (ZYEX_CID).
    One WD component (ZYEX_C) implements this ZYEX_CID.
    I have defined an additional outbound-Plug TO_X in Window inherited from ZYEX_CID.
    In the component controller of ZYEX_C i fire this additional outbound-Plug (component controller of ZYEX_C uses the window controller).
    At runtime an error is issued - outbound-Plug TO_X does not exit in ZYEX_CID.
    Error occurs only if i use ZYEX_C in another WD-Component via interface ZYEX_CID.
    Implementation of ZYEX_CID is provided via Application configuration.
    If i use ZYEX_C directly (not via interface) error ist not issued.
    Thanks.
    Regards
    Paul

    Hi ,
       Just check the provided out bound plug is marked as interface plug .  Then only you can fire this plug from the using component .

  • How to fire outbound plugs of a window?

    I have a component which I want to re-use in applications. The component should have 2 outbound (interface) plugs which can be wired into parent applications. When the user clicks buttonA in the component it should fire outboundPlugA, likewise for buttonB we have outboundPlugB. My problem is that I can only seem to fire outbound plugs of the view and not of the window.
    Until now, we've solved this by firing interface events of the component controllers but it seems plugs would be more elegant.
    How does one fire outbound plugs of the window?

    OK, I've done what you said and have the following in the event handler (action of a button) in my view:
      DATA:l_ref_test TYPE REF TO ig_comp1_window.
      l_ref_test = wd_this->get_comp1_window_CTR( ).
    The compiler error message is:
    Method "GET_COMP1_WINDOW_CTR" is unknown or PROTECTED or PRIVATE.
    This method does not exist as far as I can see.

  • Fire out plug from InterfaceView

    Hello,
    i want to check authorization for my WebDynpro-Components.
    I want to use an Authorization component, so that other components can use this component. If authorization is ok, the authorization component should fire an out plug for the using component. The out plug is created in the interface view, because the using components can plug this component only via the interface view (am i wrong?). I find no way to fire the out plug of the authorization component, because i cannot access the interface view from inside the component. Can anyone helps me?
    Thanks and regards,
    Matthias

    Hi,
    I dont think you can fire a plug from the child component to some view of the parent component.
    What you can do is, create an event in Child component. which has a authrization parameter (boolean).
    After the authorization check is done , raise the event from the child component with authorization status (success(true)or failure(false)) as the parameter to this event.
    Read this in the parent component.. and then fire the plug to the approprite view from the parent component itself.
    <a href="http://help.sap.com/saphelp_nw04/helpdata/en/24/243ca46e1c334f8a6f8b0792656bc7/content.htm">Check this for more details on implementation</a>
    Regards
    Bharathwaj

  • Fire outbound plug of interface view controller?

    Hello Experts-
        In my WD project I have two apps A and B.
        I need to navigate from app A to app B.
        In the interface view controller of app A, I have created an outbound plug called GotoB.
        I determine the URL of app B using the WDURLGenerator and store that value in a string.
        In a view of the app A I have the code:
    <code>
    wdThis.wdGetAInterfaceViewController().wdFirePlugGoToB("URLtoB");
    </code>
        For some reason nothing seems to be happening when the event triggers in the view of app A that runs the above code. The view of app A just seems to refresh. The one thing that does happen is that on the refreshed view of app A if I click on the button to trigger this event again I get an 'app A has expired' WAS error.
        What am I missing here? How can I make the navigation from app A to app B work?
    Thank you,
    - Vik.

    Hi,
    well step by step:
    1) Create component Component1 (package="com.sap.sdn", window name = "Component1CW", View name="Conponent1CV")
    2) Create component Component2 (package="com.sap.sdn", window name = "Component2CW", View name="Conponent2CV")
    3) Create application "App1" (package="com.sap.sdn", Web Dynpro component="Component2", the rest - by default)
    4) In Component1CWInterfaceView create outbound plug "GoToComp2"
    5) In Conponent1CV add Component1CWInterfaceView as required controller
    6) In Conponent1CV add button and in action handler put following:
      public void onActionGoToComp2(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent )
        //@@begin onActionGoToComp2(ServerEvent)
        wdThis.wdGetConponent1CWInterfaceViewController().wdFirePlugGoToComp2();
        //@@end
    7) In component Component2 add Component1 as Used Web Dynpto Component (name="Component1CU")
    8) In Component2CW embed view (Component1CWInterfaceView) as Embed Interface View of a Component Interface, and set this view as default.
    9) In Component2CV add inbound plug "FromComponent1"
    10) In Component2CW link embedded View Component1CU.Conponent1CWInterfaceView.GoToComp2 with Component2CV.FromComponent1
    11) Build-deploy-run. Click on button. It should work.
    Regards, Maxim R.

  • Why does fire outbound plugs sometimes don't work

    Hello.
    Can someone of you tell me what the reasons are that sometimes the firing of a outbound plug don't do the navigation?
    Many thanks,
      Mathias

    Check in the window if you have created the navigation link between the views. After defining the plugs, only if the navigation link is created, the plug will be fired properly. This could have been missed, have a look.
    Regards,
    Nithya

  • Fire OutBound Plug --- Not Working

    Hi,
    I have a Window with 2 Views. I have put 2 Naviagtional Links for the Plugs accordingly. I have a Button/Link available in View1 and want to Navigate to View2 on the action of the Button or Link. Strange thing is , When I perform the action, nothing happens. I refresh my Iview on my portal, and then when I perform the action, it works fine. I have never faced any problem in Navigation by firing plugs ever before. Can anyone suggest what coudl have gone wrong ?
    Regards,
    Murali.
    Message was edited by:
            Muralidaran Shanmugham

    Once we deleted the Instance of the Model, the problem got solved.

  • Somebody accidently unplugged my External Hard drive from my computer without going to the interface and clicking on eject first. I got the whole "you may have data loose" message. How do I find out if I really lost any files?

    That's pretty much it. Wanted to know if there is maybe a program or something that can let me know what the last things that got deleted is?

    That is a general statement that is always made when any device is not ejected, not a specific one about your hard drive. All you can do is plug it back in and hope it works. There is good chance nothing will be lost.
    There is no ready technique available to you to check the details of all of your files, you will just have to assume  they are all there.
    Unplugging a drive like that without ejecting it is most likley to affect a file when it is still being written to such as a large (media) file that takes some time to write. If nothing was being written in that split second it was unplugged, it is highly likely nothing will be damaged or lost.

  • When I call an external program from Labview, how can I embed the interface into the front panel?

    I'm running Labiew 6i for Linux. I'm using a system exec.vi to call an external program to do image manipulation (since there is no IMAQ for linux). How can I embed the user interface of the external program into the front panel of Labview?

    As far as I know, the only way to embed other GUIs in LabView is an ActiveX in a container.
    As long as you are using Linux, try to place (moving them on the desktop ) the two windows linked (like those 3 of WinAmp).

  • Fireing outbound plug of interface view from within component

    Hi all,
    is there a better way of firing an outbound plug of an wd component interface view than from within the interface view controller itself?
    The problem is, that you easly get a cyclic reference if you evaluate inbound component plugs in the interface controller (usage from int view ctrl --> int ctrl needed) and then try to fire an outbound plug from this interface controller (usage comp int --> comp int view usage needed).
    One workaround is to use some custom controller with usage of the interface view, but this doesn't seem to be a nice solution.
    So is it possible to fire outbound comp plugs from, lets say the component controller - without any usage releation to the comp int view - instead, maybe via wdComponentAPI? If yes, could you provide a code snippet?
    Thanks you and best regards,
    Christian

    Hi Christian,
    this is not possible by using the public API only, i'm afraid. It is of course possible, if you decide to forget about the possible drawbacks of using methods and classes reserved for internal use. But you have to use it at your own risk. I hacked this together some weeks ago, don't know whether it still works
    * Fires an outbound plug of an interface view with parameters.
    * @param wdComponentAPI Component API "owning" the interface view.
    * @param windowName Name of window
    * @param plugName Name of outbound plug
    * @param callerParameterMap optional Map of plug parameters.
    public static final void fireOutboundPlug(
      IWDComponent wdComponentAPI,
      String windowName,
      String plugName,
      Map callerParameterMap)
      throws WDRuntimeException {
      // Find window requested
      IWDWindowInfo windowInfo = wdComponentAPI.getComponent().getComponentInfo().findInWindows(windowName);
      if (windowInfo == null) {
        throw new WDRuntimeException(
          "Can't find window: " + windowName + " in component: " + wdComponentAPI.getQualifiedName());
      // Get info of interface view
      IWDInterfaceViewInfo ifViewInfo = windowInfo.getInterfaceView();
      if (ifViewInfo == null) {
        throw new WDRuntimeException("Window: " + windowName + ", no interface view info found");
      // Find outbound plug
      IWDOutboundPlugInfo outboundPlug = ifViewInfo.findInOutboundPlugs(plugName);
      if (outboundPlug == null) {
        throw new WDRuntimeException(
          "The interface view: " + ifViewInfo.getName() + " has no outbound plug: " + plugName);
      // Parameter passing
      Collection plugParameters = outboundPlug.getParameters();
      // TODO make check optional, check caller map parameter keys against existing
      if (plugParameters == null || plugParameters.isEmpty()) {
        // No caller parameters allowed.
        if (callerParameterMap != null && !callerParameterMap.isEmpty()) {
          throw new WDRuntimeException(
            "The outbound plug: " + plugName + " has no parameters, callerParams must be empty/null.");
      // TODO This is a hack, use of internal WD runtime classes and methods (don't use productive).
      InterfaceView ifViewController =
        (InterfaceView) ((Component) wdComponentAPI.getComponent()).getController(ifViewInfo.getName());
      ifViewController.navigate(outboundPlug.getName(), callerParameterMap);
    Please remember, that not everything which is technically possible, makes sense
    Regards
    Stefan

  • Fire Plug from one window to another

    Dear All,
    Is it possile to fire an outbound plug from one window to another?
    I am using a Popup window and on clicking a button in the popup window, I want to navigate to another view in the parent window.
    I know there are other ways to handle these kind of scenarios like using an eventhandler in the parent view and them firing a plug, but that would affect the rest of the applicatin flow.
    So I cannot avoid firing the plug from the view in the popup window.
    Can it be done?
    Thanks and regards,
    Mayuresh

    Hi Mayuresh Kanvinde ,
          I believe your popup is a modal window. If so in your action handler of the button on the popup window you can hide the popup window and then fire the navigation plug of your parent window.
       Your popup button action handler can call a method in your component controller where you can write the code to hide the existing popup window and then fire the plug in your parent window.
       make sure you store the IWDWindow object of your popup window on the context so that you have access to it to hide the popup window.
    Regards,
    Sanyev

  • Fire WindowInterfaceView outbound plug

    For my webdynpro I use cross-component navigation.
    From ComponentA, ViewA i'm using a plug to navigate to ComponentB, ViewB.
    Now I want to navigate back to ComponentA, ViewA when the user press Cancel.
    I created a outbound plug in my WindowInterfaceView with a link to the inbound plug from viewA.
    How can I fire this plug in the WindowInterfaceView from ViewB?
    Regards,
    Björn

    Hallo B.
    what's the problem? You just apply the same technique twice.  You navigate back to CompB from CompA just like you navigated from CompB to CompA before?
    You declare an additional outbound plug on the interface view of CompB and link it to an interface view inbound plug of CompB.
    Firing the outbound plug from WindowInterfaceView (you mean ComponentInterfaceView which is 1:1-related with a Window inside the component) is explained in the tutorial:
    public void onActionNavigateBackToUICompB( com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent, int targetView )
    //@@begin onActionNavigateBackToUICompB(ServerEvent)
    wdThis.wdGetUICompAInterfaceViewController() .wdFirePlugBackToOtherCompOut(targetView);
    //@@end
    I allready adapted the code to your question.
    Regards, Bertram

  • Why do we need mention explicitly for Outbound plugs?

    Hello
    When i see a existing custom WD component's my_view's method code (action is APPROVE), i  see the below code
      wd_this->fire_tomain_plg( ).
    I also saw that MAIN view is the outbound plug for my_ view.
    1) Is this code is telling to the system that, it should navighate to MAIN view?
    2) if so, already we put this (TOMAIN) in OUTBOUND tab righ? why again having this piece of code EXPLICITLY in our method?
    3) is we (developers) need to put this manually? or or systme will put it at the bottom of the method automatically?
    4) but i did not see any such code for INBOUND PLUGs? why?
    Thank you

    ABAP_SAP_ABAP wrote:
    Hello
    >
    > When i see a existing custom WD component's my_view's method code (action is APPROVE), i  see the below code
    >
      wd_this->fire_tomain_plg( ).
    >
    > I also saw that MAIN view is the outbound plug for my_ view.
    >
    > 1) Is this code is telling to the system that, it should navighate to MAIN view?
    >  YES.
    > 2) if so, already we put this (TOMAIN) in OUTBOUND tab righ? why again having this piece of code EXPLICITLY in our method?
    >  In the outbound tab, you are specifying list of outbound plugs which can be used. however you need to fire the correct outbound plug via coding.
    > 3) is we (developers) need to put this manually? or or systme will put it at the bottom of the method automatically?
    >  You need to fire outbound plug for navigation. You can use WDA wizard to do that.
    > 4) but i did not see any such code for INBOUND PLUGs? why?
    >   We maintain navigation link b/w outbound and inbound plug at Window. This will automatically fire inbound plug corresponding to outbound plug.
    > Thank you

  • Firing Exit plug from the embedded component

    Hello All,
    I am working on a scenario where I am developing a Webdynpro component which is child to the MainComponent.
    MainComponent view has links to access my child component as I have exposed my child component as Public part.
    Once my application is access by MainComponent, I can only go back to MainComponent.
    Now I need to fire an exit plug with URL (say sdn.sap.com) from my child component which will open new URL in same browser.
    When I defined exit plug and passed on Url parameter to it, my component throughs exception saying "Cannot fire exit plug from embedded component".
    Is there anyway I can achieve this?
    Please guide me.
    Ashutosh

    Ashutosh,
    <i>I can not use WDClientUser.forceLogoffClientUser(url) as I need user to be logged in.</i>
    Actually, no. It is optional -- you may be either logged-in or not, in later case WD runs under some internal Guest account. So forceLogoffClientUser works in either case.
    Valery Silaev
    SaM Solutions
    http://www.sam-solutions.net

Maybe you are looking for

  • Computer error - 'Out of Memory'

    Hi all, Company I edit for bought a new tower. Here are the specs Processor Two 2.66GHz 6-Core Intel Xeon RAM 12GB Graphics Card ATI Radeon HD 5870 1GB Yesterday was my first day on it, and all went fine until I started bringing render-heavy motion f

  • How to query usr_created in OIM 10g

    Hi , I am working in OIM 10g. I need to get users who got created or updated with todays date. but i am not able to query that in sql dev select * from usr where usr_created ='29-OCT-12'; is not returning any result any suggestions please Thanks

  • Making a Ringtone isnt working??

    I click on a song I have purchased from the Itunes store....I click the bell (or click store, create ringtone), it pulls up the editor....I select 30 secs of the song in a proper spot, I check the spacing and preview it, then I click "Buy", it asks t

  • My sister's MacBook white is running slow lately

    My older sister got her laptop back in 2012, and its ran like a champ since then, i even updated it from OS X 10.6.8 to OS X 10.7.5 and it ran even better! but lately, it's started to lag when doing normal tasks, like running basic safari application

  • JPanel's Graphics disappears!!

    When calling jpanel.getGraphics().drawLine(...), for example, the line is drawn on a panel. But when another window is dragged over this panel, the graphics is erased(it is in memory, but it's not shown on a panel). How to avoid this problem? (Someon