Fire plug on another window

Hi All,
I need to use a popup window that has a startup plug that must be initialized. The window contains a view that is referenced from another DC (That means that the only way to communicate with it is via plugs).
I know how to do the popup, but I don't know how to call its startup plug directly from the code.
The final scenario should be as follows:
1) The initial view has a button
2) When pressing the button the referenced view is displayed as a modal popup (I need to pass parameters to this view).
3) In the popup there is also a button that when clicked sends the selected information and closes.
4) The selected information is displayed on the initial view.
Thanks,
Aviad

Hi Aviad,
For creating and getting the values from one window to other you can use the Events. Follow these steps:
1) Go to the Component controller. Create a new <i>EVENT</i> there, say <b>setValue</b> and a Method say <b>setFinalValue().</b>
2) Create a attribute of type string in controller context, say <b>text</b>.
3) In the 1st window from which you want to pass the value, create a METHOD, say <b>SettingValue();</b>
4) In this method (ie:<i>SettingValue()</i> ), write a code to set the value of text and call the event of the controller.
To the the value of text:
wdThis.wdGet<Controller_Name>().wdGetContext().currentContextElement().setText("Any Value");
To call the event:
wdThis.wdGet<Controller_Name>().setFinalValue();
5) In the controller code write this code in the setFinalValue method.
public void setFinalValue( )  {
    //@@begin setFinalValue()
       wdThis.wdFireEventSetValue();
    //@@end
6) In the next window where you want to access this value create a Event Handler in the View of it.
<i>Methods-> New - >Event Handler-> Next -> Give name (say <b>setTextForCell</b>). Select the Event Source (ie: <i>Name of the controller</i>) and set the subscribed Event (ie: <b>setValue</b>).</i>
7) In the implementation write this code to get the set value
public void setTextForCell(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent )
    //@@begin setTextForCell(ServerEvent)
       String text = wdThis.wdGet<Controller_Name>().wdGetContext().currentContextElement().getText();
     Use this value anywhere you want
    //@@end
I hope this will solve your problem.
Regards
Pravesh
Ps: Please consider rewarding points if helpful and solved.

Similar Messages

  • 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

  • When fire fox open another window, that window do not direct me to any website...

    hello, when firefox directs me to another website, a window open but that window do not load the website, just stay clean...
    for exemple, when i go to youtube and try send a video to my facebook, i click on the facebook button, one firefox window open, but do not directs me to any website, that window just remain white...

    Try reading the following articles:
    [[Reset Firefox – easily fix most problems]]
    [[Firefox can't load websites but other browsers can]]

  • 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.

  • My iTunes isn't reading my IPhone 5 and I have the newest iTunes update 11.0.3 I use a windows computer, when I plug my iPhone to another windows laptop it reads it, except mine

    My iTunes isn't reading my IPhone 5 and I have the newest iTunes update 11.0.3 I use a windows computer, when I plug my iPhone to another windows laptop it reads it, except mine

    Take a look at this link, http://support.apple.com/kb/TS1538

  • Call another component on fire plug..

    Hi All
    Assume the following set up - Comp A (view1) and Comp B (view2). I enter some data in view1 and it should be displayed in view2. Via the Interface controllers, I have done the relevant mappings so that data of Comp A (view 1) can be accessed in Comp B (view 2).
    Now, how do i navigate from view 1 to view 2 to see the data and back to view 1 on clicking of a button in view 2...?? Different options could be:
    1. Use fire plugs to do the navigation.
    2. Or some other eventing mechanism.
    Request you to please suggest me different ways (step by step in detail) on how we can achive this with the above 2 ways or if there are other ways also.
    (For this sample app, I am using a standalone WD Project, no concept of Development Components here and at the moment Comp A is added in the Used Components of Comp B to access Comp A (view 1) data... )
    Thanks
    Deepak

    Hi Deepak,
    There are actually two ways to pass values when you are using plugs to navigate.
    1. In both the target and the source view, you have a tab called plugs if you can see. under this, all the inboundt and the outbound plugs are defined. When you click on any of the plug, you have a provision to enter the parameter to be passed with the plugs. So, you define the same parameter name for the outbound plug of the View1 and the inbound plug of View2. These parameters would be passed as arguments on firing of the plug as you can see in the implementation. Similarly, you can define N number of parameters of your data type. So, when the plug is fired, these parameters are passed.
    All you have to do is set the parameter value when firing the plug as
    wdThis.wdFirePlug<OutboundPlugName>(wdcontext.currentContextElement().getVa_Para1, 20);
    Same is possible when you are using plugs between view and interface view. Just have a look.
    Similarly, in the onPlug<YourInboundPlugOfView2>(value1, value2) method of View2 ,
    you can get the values and set it to context or whatever by directly using the variables value1 and value2.
    2. You can set the value(s) to be passed in context of View1 and define same context variable or node(with same structure) in View 2 and also in the component interface Controller of both the views . Now View1 can be mapped to Component Interface of Comp1 and View2 to Component interface of Comp2. But, you need to map both the Comp1 and Comp2 too to pass the value.
    [Remember, mapping will help you to pass from 1 to 2 and 2 to 1, either ways because it is coming via Component Controller/Interface Controller. During navigation only views are destroyed and not the Component, so it will be stored there. making change at one place would be reflected to all the faces where mapping is done.]
    So, you add the Comp2 in the Used Component of Comp1 first and then you can add dependency over Comp2 in the properties tab of Comp1. Then you can do mapping and call the methods defined in Comp2 in Comp1. Same can be done to add Comp1 as used Component of Comp2.
    Hope you understood. Try doing it..you will understand.
    Regards,
    Tushar

  • Calling parent's view inbound plug from modal window?

    Hi,
    I have a window A with a view ("the parent") that calls another window B as a modal one. This window B uses own buttons for actions, no standard ones (OK, Yes, No ...). The problem is that the actions in window B are changing the content in window A. I want  that after closing the modal window B a specific inbound plug of the view of the other window A is called (where a refreshing mechanism is available). How to do that? I tried with the - at other posts - suggested method of exit-plugs, but that didn't work (because outbound and requested inbound plug belong to different windows ???).
    Thanks for your help,
    Alexander

    Hi,
    thanks for your reply. My problem was that in my popup window no standard buttons are available, so that the SET_ON_CLOSE_ACTION can't be used (cf. documentation it only works with the CANCEL-Button). But with this hint I was able to find another solution (which was by the way explained in another thread answered by you 8-) ): I have to create an event in the component controller and fire this event from my window B. Then I have to subscribe a method of window/view A to that event which does the required refreshing. [trigger event from "child" webdynpro;.
    Best regards,
    Alexander

  • Can't download plug in for windows media player. Have used download site and it says it worked, but plug in is not showing up on my list of plug ins.

    I tried to hear a conference call on a website. Got a message, needed windows media plug in. Checked my plug ins, no windows media. Read tutorial on firefox support. Clicked on download. Got a window that asked for repair or change. Tried repair, then change. Need better directions on how to finish download. Got message download successful, but after closing firefox and reopening, still no plug in for windows media in list of plug ins. Went to site and could not hear conference.
    Read support forum. Message about using about:config. Tried this, typed in about: config in start menu, but didn't see anything that looked like I could change to true like message said.
    solved by opening internet explorer and going to website and listening to conference call on windows media player. There was a message saying click here if you want to enable media player. Did so, heard conference.
    Tried using chrome. Got to hear conference yesterday. Today, there was same message about needing plug in when I tried to follow instructions to get plug in, it was as confusing and useless as firefox. The bottom line is I tried to do everything set forth in firefox's forum suggestions and can't get the windown media plug in to show up in my list of plug ins and can't hear conference calls on firefox.
    Chrome did say they were working on getting plug in available at chrome store.
    I agree with comments that I was able to go to web sites and hear calls before firefox made an update that removed my windows media plug in. The simple download fix, presumeably from windows, does not work, apparently because firefox can't find the fix. That is not the user's fault, and it looks like windows tried to provide a fix, and firefox won't recognize it.
    Bottom line, it is easier to use another browser, than try and get the windows media player plug in installed on firefox. What good is a browser, if you can't hear a call on the website that the browser takes you to? Please make it easy to install the windows media plug in on firefox. Thank you..

    Firefox can find plugins in several locations, but Firefox 21 changed the location of the "shared" plugin folder so older installers like the Microsoft Windows Media Plugin no longer drop the DLL file in the correct location.
    There apparently are two ways to address this:
    (1) Change a Firefox preference so that Firefox checks the old location. Here's how:
    (i) In a new tab, type or paste '''about:config''' in the address bar and press Enter. Click the button promising to be careful.
    (ii) In the filter box, type or paste '''plugins''' and pause while the list is filtered
    (iii) Double-click '''plugins.load_appdir_plugins''' to switch its value from false to true.
    This will take effect after you restart Firefox.
    (2) Copy the plugins folder to the new location. Here's how on Win 7 64-bit:
    Open a Windows Explorer window to:
    C:\Program Files (x86)\Mozilla Firefox
    Right-click and copy the '''Plugins''' folder
    Double-click the '''browser''' folder to open it
    Right-click and paste
    Right-click the new copy of '''Plugins''' and rename it to '''plugins'''
    After restarting Firefox, the plugins in that folder should now be available.
    ''Edit: I suggest just doing #1.''

  • I downloaded an album from iTunes on my iPad and then i synced it with iTunes it doesn't show the individual songs in my library just the album which opens another window.  Can you help?

    I downloaded an album from iTunes on my iPad and then i synced it with iTunes it doesn't show the individual songs in my library just the album which opens another window.  One of the albums won't even play the music.  Will only open the "booklet" for the cd but not the music.  Can you help?

    Hello dannugget
    Normally, if the songs showed that it is purchased then it is probably already in your library. If not check out the article below to walk you through downloading your past purchases. You may also want to check to see if you have Automatic Downloads turned on so that way next time you can get your tracks without having to plug in and sync.
    Download past purchases
    http://support.apple.com/kb/ht2519
    iTunes Store: How to enable Automatic Downloads
    http://support.apple.com/kb/ht4539
    Regards,
    -Norm G.

  • IPhone 3G plugged into PC(Windows 7) 'USB is Not Recognized' and unable to restore; stuck on 'Connect to iTunes'

    iPhone 3G plugged into PC(Windows 7) 'USB is Not Recognized' and unable to restore; stuck on 'Connect to iTunes'
    I was in the process of putting another firmware for my iPhone(an .ipsw via. itunes) and the house had a power cut. The computer was in the middle of restoring the iPhone but never finished. The apple logo came on and then came onto the 'connect to itunes' screen. My sim card was in but there is no option to slide for emergency. When I Plug it into my computer, a message pops up saying that the 'USB Device Not Recognized', I've tried to plugging my iPhone into my laptop and other Computers but the same message occurs (all windows 7). Other articles say that the error is with the iPhone, I need help!! Can anybody offer some advice on what to do?
    oh yeah, bit tight so not willing to spend any money;-)

    Apple support:
    Network Printer Troubleshooting
    Reset Printing System

  • Call an Startup-Plug from another WDA

    Hello.
    How can I call a Startup-Plug from another WDApplication with a table-Parameters.
    I get the URL from the Method cl_wd_utilities=>constuct_wd_url.
    thanks for helping
    Edited by: Marcus Ventur on Dec 2, 2008 11:33 AM

    Hi,
    Try to start your secondary application with a URL Parameter,
    then fire any plug you want by checking the parameter,
    hope it helps,
    regards

  • I can't download firefox. When I click on run, I get a window saying that the author is unknown. When I click on run in the new window, another window says the file is corrupt. What can I do about this?

    I want to have firefox as my default browser. As this is a new laptop, I hasve to download firefox. As per the instructions, I click on "run" to complete the download, but instead of completing the download, a window appears which says that the author is unknown. If I ignore the window and click on run, I get another window which says the file is corrupt and I can't finish the download and have firefox as my browser.
    I have windows 7 and explorer is the default browser and I want to change to firefox, but so far am being prevented from doing so. How can I successfully download firefox?

    It is possible that your anti-virus software is corrupting the downloaded files or otherwise interfering with downloading files by Firefox.
    Try to disable the real-time (live) scanning of files in your anti-virus software temporarily to see if that makes downloading work.
    See also:
    * http://kb.mozillazine.org/Unable_to_save_or_download_files

  • HT2492 How do I use the calculator widget in another window?

    How do I use the calculator widget in another window?  For ex: if I want to move the calculator to a window that shows prices of products on a web page.  I used to be able to click on the calculator and use it in another window, before I upgraded to OSX. What am i doing wrong?

    I think you have to bring it back up in widgets in a new window, you can set up a hot corner to make tis qciker

  • When I move my curser over certain things I get this Message in a window that pops up and says "We noticed you may have signed in or signed out in another window click ok to reload your page." How do I get this to stop.

    When I move my curser over certain things I get this Message in a window that pops up and says "We noticed you may have signed in or signed out in another window click ok to reload your page." How do I get this to stop.

    Clear the cache and the cookies from sites that cause problems.
    * "Clear the Cache": Tools > Options > Advanced > Network > Offline Storage (Cache): "Clear Now"
    * "Remove the Cookies" from sites causing problems: Tools > Options > Privacy > Cookies: "Show Cookies"
    You may have to create an Allow cookie exception for that server.
    * Tools > Page Info > Permissions

  • Closing one of the opening windows tries to close all tabs on another window

    I opened two windows, one with multiple tabs and another is no tab, when closing a window with no tab, a prompt window appears and ask if I want to close all tabs on another window. Prompt window appeared twice. Is this a bug?

    I also had this issue and disabling the Awesome Screenshot add-on fixed it for me too. Its not doing it anymore after disabling that plugin. Thanks for the tip!!!

Maybe you are looking for

  • Slow Browsing and Streaming

    Since last Monday ive had extremely sluggish browsing speeds and buffering video even on low settings, my speed tests come back around 44mb (My ip profile was 63mb and is now lowered 47mb) and on applications like Steam I am getting those speeds, but

  • How do I take someone else's iTunes account off my computer

    I helped my brother with his iphone a few weeks ago and he authorized my computer for his account so we could change some of his songs and what not but it synced his apps to my computer, ive deleted them and moved on cause I didnt have an iphone. Wel

  • Using my iMac as a main display for a MacBook

    I'm thinking about getting myself a MacBook Pro to replace my iMac, which I got in 2008. My question is, would it be possible to keep my current iMac and connect a MacBook to it, so that the screen of the iMac can be used as a main display for the Ma

  • SOAP Receiver Error: HTTP Error response for SOAP Request

    Hi gurus, I'm facing a weird error in File --> PI 7.31 java only --> soap receiver proxy. The other interfaces runs well. just one get the the following error: Exception caught by adapter framework: java.io.IOException: Error receiving or parsing req

  • Retrofit issue

    Hi Experts, We have created TR in SE2:300 (SE2K900212) and after releasing it, we have got Transport Of Copies (SE2K900214). Now object which is relevant with Zpackage25 under this TR, we want that to move to SE2:200 client through automatic retrofit