On Blur, On Click Events in Web Dynpro - How can it be done ?

Hello All,
I am wondering if it would be possible to have
On_CLick
and
On_Blur
events using Web Dynpros, it would be great if any one can tell me how it is done or provide me some documentation, I have done it using HTMLB but dont know how to do it using Web Dynpros.
I would appreciate any help.
Best Wishes,
John.

Hi John,
As Maksim said you can use the onClick event with some of the UIElement.
for example:
Add a button UIElement to your view
create a new action in the view.
Write in the action something like:
wdComponentAPI.getMessageManager().reportSuccess("Hello John");
In the properties of the button you will see an onAction event. Bind it to the action that you created.
Regards, Adi.

Similar Messages

  • Eventing between Web Dynpro iView and regular DynPage iView

    I have seen, done eventing between two dynpage iviews and two webdynpro iviewsHowever, and gone through "How to Use the Portal Eventing for Web Dynpro iViews". However, I have been trying to have a webdynpro iview talk to a dynpage iview but they just won't communicate. Is this even possible?
    Ok basically I have a portal page in a popup window with no masthead and top level navigation. The page has two iviews -  the top one being an iView that points to a webdynpro application on Server A, and the bottom one being a dynpage iview on the Portal Server B.
    In the webdynpro iview, the code for when a button is clicked is
    public onSomeAction(Event event) {
        WDPortalEventing.fire("urn:myUrn","eventName","value");
    In the dynpage iview, the code i have for it is
    myServ = (IEpcfToolbox) PortalRuntime.getRuntimeResources().getService(IEpcfToolbox.KEY);
    myReceiver = myServ.getClientEventReceiver(request, "urn:myUrn", "eventName");
    form.addRawText(myReceiver.getWrappedScript());
    try {
        if (!myReceiver.isReceived()) {
            form.addComponent(createMainScreen());
        } else {
         form.addComponent(new TextView("event received!"));
    } catch (Exception e) {       
        form.addComponent(createErrorScreen());
    I tried all the things I could think of but the receiving iView just won't get the event fired.
    Can someone confirm that this should work? and correct me where I've done wrong.
    Please help. this is very urgent. your help will be greatly appreciated. thanks in advance
    PS. My environments are EP 6.0 SP2 and WAS 6.40 SP14

    > hi,
    >
    > portal eventing  works properly if all participants
    > are in the same domain. Otherwise portal eventing
    > g does not work. If the SAP J2EE
    > Engine on which the Web Dynpro application is
    > deployed is in another domain, you have to  map the
    > IP address of the SAP J2EE Engine to the domain name
    > of the
    > SAP J2EE Engine on which the SAP Enterprise Portal is
    > running, by editing the configuration file hosts.
    >
    > regards,
    >
    > Ganesh.N
    I am no direct access to the boxes so I can't try your suggestion. It really makes sense that eventing won't work if the iViews are on different domains. I know they are in the same domain but different subdomains.
    Anyway, good news I got eventing to work with the mentioned set. I found that that the SAP Java EPCFToolbox API had a bug that kept throwing javascript errors when I tried to have the web dynpro iview fire an event and the SAP one subcribed to it.
    I got around it but using the EPCF Javascript API instead.
    Code:
    response.write("<script>");
    response.write("EPCM.subscribeEvent('urn:dla.telework', 'createPdf', doSomething);");
    response.write("function doSomething() {");
    response.write("window.location = self.location + '&eventReceived=true';");
    response.write("}");
    response.write("</script>");
    So basically just output raw text through the response object and it just works.
    On a similar topic, since eventing can only pass string parameters back and forth, I'm still looking for a way to pass other more complex Java objects between web dynpro and sap iviews. From what I haven't they don't share the same session object (which I thought they did). So basically I can't just stick stuff in the session and pull it down on the other end. I'm clueless right now. If anybody has some tips, plesae share. Thanks

  • Handling standard iview event from web dynpro

    Hi all,
    I hav w a search iView which is SAP standard, when you click an element on the result list it triggers an event. The link contains the following:
    javascript:{jsCode="
    EPCM.storeClientData('urn:com.sap.bor:BUS1001','objid','12002');
    EPCM.storeClientData('urn:com.sap.bor:BUS1001','AllKeys','objid');
    EPCM.raiseEvent('urn:com.sap.bor:BUS1001','select','','a very long url');"};if(opener!=null&&self!=opener){opener.execJS(jsCode);}else{execJS(jsCode);};
    On the other side I'm developing a custom WebDynpro iView whick needs to handle this event. By adding to wdInit() the line WDPortalEventing.subscribe("urn:com.sap.bor:BUS1001", "select", wdThis.wdGetGetReportsListForMaterialAction());  I was able to catch the event. But I can't get the parameters from the event.
    For what i've learned browsing the forum the javascript code above stores the parameters in the "client data bag", and are not directly passed in the event.
    Is there any way to retrieve these parameters from the Web Dynpro iView ?
    Thanks in advance,
    Diego.

    Hi all,
    As a workaround I made a Portal Component application which receives the event and parameters from the standard iView and lanuchs a new event setting the aprameters in the event as Web Dynpro expects them (without using the client databag). Then I inserted this Iview in the same page as the others, but hidden. It's not elegant but is working.

  • Push data/ trigger event in Web Dynpro app

    Hello All.
    I'm a newbie with web dynpro.  I have a need to “push” information to a web dynpro application.  Is there a way I can trigger an event in web dynpro to refresh the screen from another application running on the Netweaver J2EE?  Is it possible to implement an ActiveX or AJAX  application to retrieve server data and communicate with a web dynpro app running on the enterprise portal?
    Your help will be appreciated.
    Mohan

    Hi,
    You can search for portal eventing...subtscribing event and unsubscribe it etc.
    Regards,
    Kiran Chennapai

  • In Web Dynpro ABAP, Can we merge two cells of a row in a table ?

    In Web Dynpro ABAP, Can we merge two cells of a row in a table ?

    Hallo Jagannatha,
    the new table feature is available in SAP NetWeaver 7.0 EhP2 (SAP ERP 6.0 EhP5, SAP Business Suite 7i2010) named 'TableMultiEditorCell'. See [SAP Online Help|http://help.sap.com/saphelp_nw70ehp2/helpdata/en/9b/46bb0d339b42cc8d30636ca0c9f5b6/frameset.htm] for more details ...
    "This UI element is a table cell variant that enables several UI elements to be placed in one table cell. This type of cell can be used for "one click actions". ...
    Regards, Bertram

  • I am receiving a message that says "sorry you browser/program isn't supported by Web Dynpro" what can I do?

    I am receiving a message that says "sorry you browser/program isn't supported by Web Dynpro" what can I do?

    See:
    * http://boardreader.com/thread/Problems_with_Web_Dynpro_and_Firefox_4_6rv33X159dx.html

  • After a HD crash, I have to reinstall Photoshop Element 12 and Premier Element 12. I still see the link in my purchases history but nothing happens when I click on the link. How can I get my softwares back?

    After a HD crash, I have to reinstall Photoshop Element 12 and Premier Element 12. I still see the link in my purchases history but nothing happens when I click on the link. How can I get my softwares back?

    Jeanval have you tried a different web browser?  For more information on how to download your purchased software please see http://helpx.adobe.com/creative-suite/kb/find-download-link.html.

  • After update I am no longer able to open email attachments by just clicking on the attachment. I now have to click control and then click open linked file. How can I open attachments by simply clicking on them?

    After update I am no longer able to open email attachments by just clicking on the attachment. I now have to click control and then click open linked file. How can I open attachments by simply clicking on them?

    Unless you believe middle-click is yours and don't like it being usurped, mine is set globally to "Enter".

  • When I want to delete a meeting I have the message "the attendee may not change the event". How can it be done?

    When I want to delete a meeting I have the message "the attendee may not change the event". How can it be done?
    Quand je veux effacer un RV le message "the attendee may not change the event". Comment faire?

    You indicate you have just started using Thunderbird, so what email program displays them "as usual"

  • Catch event from Web Dynpro for Java

    Dear guru's,
    we have a working Web Dynpro for Java. It delivers a company code that needs to be routed to a visual composer model. In the Web Dynpro we use the WDPortalEventing.fire command to trigger an event named 'ShowCompanyCode' in namespace com.sap.vc:epcm. In the visual composer, I used a 'signal in' for the same namespace and event name. However, the supplied value for the company code is not received. Both iviews (from VC and Web Dynpro) are on one page.
    I have enabled the flash debug console and did some testing with a VC model that consists of two iviews on one page. Here it does work. I have found some differences in the debug output that points in a direction.
    In the case of the VC iviews, I get the following string in the debug console: signalinAHAPP -<Params version="2" ><Row STR1="1000" /></Params>. This results in a correct transfer of company code value '1000'.
    When getting the info from the Web Dynpro iview, I get the following string:  signalinAHAO8 -1000. It seems that the web dynpro does not supply the values in a correct way. However, the same mechanism is used to supply the data to another web dynpro iview and that works fine.
    Do we have to use special coding to be able to fire the event to a VC iview? Any help will be appreciated and points will be awarded!
    Thanks,
    Arno

    A. Van de Camp,
    You can create two iViews that communicate with each other on the same page, using client-side eventing, so that the output of the first iView serves as the input to the second. Eventing in the portal is based on the use of the Enterprise Portal Client Manager (EPCM), an object defined by the portal client framework to handle functions such as client eventing.
    To define eventing between an iView created and existing in the portal(web dynpro iview), and an iView created in Visual Composer:
    1.Check the properties of the existing portal iView and find out its EPCM event name.
    2. In Storyboard, open the iView that is to be the second part of the eventing scenario and create the required port: as input or as output.
    3. Double-click the newly-created port and in the Configure Element task panel, enter the portal event name in the Signal name field and the EPCM event in the EPCM event field.
    Regards,
    Sami

  • Portal Eventing between Web DynPro Java iView and non-Web DynPro iView

    Dear Experts,
    I have 1 Web DynPro Java iView and 1 non-Web DynPro (using JSPDynPage and JSP) iView, both attached to a page. When Web DynPro Java iView fire a portal raise event, the portal iView did not execute the javascript function tied to the event subscribed.
    Here is the code snippet which reside in the Web DynPro Java iView that is used to fire the event
    String param = "test";
    WPortalEventing.fire("urn:com.company.Test1", "TestEvent", param);
    This the code snippet that is in the jsp page
    function notifyTest(param)
         // Code to print param value here
    EPCM.subscribeEvent("urn:com.company.Test1", "TestEvent", notifyTest);
    Note:
    1. When Web DynPro Java iView fire the portal event the entire page is refreshed, including the non-WDP iView.
    2. When EPCM is replaced with window.top.EPCM, the page is refreshed, it is totally hanged with progress bar.
    Can anyone help to solve this problem?

    hi
    Please write the below code snippet in ur jsp for notifyTestjavascriptfunction
    function notifyTest( eventObj ) {
         eventParameter=eventObj.dataObject;
         // code to print the parameter "eventParameter"
    Thanks
    Harsimran

  • Portal Events in web dynpro

    Hi All,
    I have created two web dynpro application iviews on the same page.
    Now there is a button on the first application and when that button is pressed then I am triggering an event TRIGGER from it using method FIRE.
    There is a text edit element on the second application.
    I have registered the event TRIGGER in the second application in method WDDOINIT using method SUBSCRIBE_EVENT and assigned an action RECEIVE to it.In the method ONACTIONRECEIVE I have set data to be displayed in the text edit element.
    However the above scenario is not working.
    In methods subscribe_event and fire there is a parameter to be passed which is PORTAL_EVENT_NAMESPACE.What exactly is this parameter and what value to be passed to it.
    Please provide any source code if any.
    Thanks in advance
    Aman Gupta

    Hi Aman,
    If you are still not able to do the Portal eventing then to make portal eventing work you should access portal using FQDN (fully qualified domain name).
    Check Sap help for [Fully Qualified Domain Names |http://help.sap.com/saphelp_nw70/helpdata/en/67/be9442572e1231e10000000a1550b0/content.htm] also check the SAP note 654982.

  • Add an Event in Web dynpro for Cancel option

    Hi Everyone,
    I have a scenario where in which , I have a search help option and when users hits of search help a window pops up and when user selects any it populates the data into feild.
    Now that i want to add a cancel button in the F4 window .
    How can  go about and do this.
    Please provide me step by step approach as most of the web dynpro I am not aware of... i am new and learning on my own.
    Regards,
    Raj

    Kandaraj,
    Using window instance you can implement the cancel functionality,
    Create a context in your component controller "WindowInstance" with the type type     "com.sap.tc.webdynpro.services.session.api.IWDWindow"
    User this method in you component controller,
    /**********************COMPONENT CONTROLLER***************************
    public void showpopup( )
    IWDWindowInfo winInfo = wdComponentAPI.getComponentInfo().findInWindows("PopupWin"); // PopupWin -> Name of your window
        IWDWindow win = wdComponentAPI.getWindowManager().createModalWindow(winInfo);
        win.setWindowPosition(300,150);
        win.setTitle("Your Account Infomation");
           win.setWindowSize(200,200);
        wdContext.currentContextElement().setWindowInstance(win);
        win.show();
    call the method from the View
    *************Create a Window for Popup*************************
    Create a View for New Window
    Create a context in your component controller (Popup Window) "WindowInstance" with the type type     "com.sap.tc.webdynpro.services.session.api.IWDWindow"
    Open the View of Popup Window
    Create a Button and action for the button
    Put this code inside the action method:
      IWDWindow win = wdContext.currentContextElement().getWindowInstance();
        win.close();
    Ram

  • [Web Dynpro]How to add a new function in the implementation of a view?

    Hi, all,
       I'm trying to add a inputfield check method in the viewname.java , the method is used to check all the 12 inputfields in the view, at least one inputfield should be filled.(Is there any other methods I can use to do this job?)
    however, when I clicked the save meta data button, the function disappeared from the viewname.java. The import statements were still there and showed that they are never used...
       Could you please give me some hints to avoiding this?
       I want to save my function in the viewname.java.
    Thank you in advance.

    Hi folks,
    I'm somewhat new to WebDynpro and when I want to declare my own methods I generaly put them at the bottom of the file underneath the comment;
       * The following code section can be used for any Java code that is
       * not to be visible to other controllers/views or that contains constructs
       * currently not supported directly by Web Dynpro (such as inner classes or
       * member variables etc.). </p>
       * Note: The content of this section is in no way managed/controlled
       * by the Web Dynpro Designtime or the Web Dynpro Runtime.
      //@@begin others
    This way I can delare them as private methods for the class. Am I wrong in saying that anything you declare in the 'Methods' tab will be public?
    Since I'm new to WebDynpro I don't know all the best practices so any clarification here will be appreciated.
    Regards,
    Patrick.

  • Closing window of web dynpro application with exit-plug don't run in the EP

    Hi everybody,
    I want to close a window that contains a Web Dynpro with a close button, because it's used and create as a popup from an other iView (that's not created with web dynpros) in the EP. I read the different threads how to close a window in web dynpro, like JavaScript in WD
    I create a HTML file with the javascript code to close the window and it works fine, when I start the application separately.
    If I used it in the portal and click the close button I get the following error message:
    com.sap.tc.webdynpro.services.exceptions.WDRuntimeException: Exit-Plug must no be triggered with an URL when running in portal. Use portal navigation instead to navigate to another application!
    I tried also: ...wdFirePlugExit("javascript:self.parent.close();") or some other javascript code, but got the same error message.
    Then I tried:
    WDPortalNavigation.navigateAbsolute(url,WDPortalNavigationMode.SHOW_INPLACE,(String) null, (String) null,(String) null);
    instead of fireing the outbound plug in the action of the close button
    (...InterfaceViewController().wdFirePlugExit(url);)
    but than a new window with the EP open and the old is still there!
    We use the NWDS2004s an the EP 7.00.
    It must be possible to close a (this) window!
    Thanks for any hint
    christian

    Hi,
       This is what you can do:
    1. You have already created the HTML file with the necessary javascript in the foloowing folder structure :
    src->Mimes->Components-><your component name>-><fileName.html>.
    2. Create a new iView of type URL in your portal.
    3. Get the absolute URL of this HTML file inside your project. This will be in the following format:
    http://<server>:<port>/webdynpro/resources/sap.com/<development ComponentName>/Components/<namespace>/<fileName>.html
    You can find it thus:
    try {
    String u = WDURLGenerator.getAbsoluteWebResourceURL(wdComponentAPI.getDeployableObjectPart(),"filename.html");
    wdComponentAPI.getMessageManager().reportSuccess(u);
    } catch (WDURLException e) {
    // TODO Auto-generated catch block
    e.printStackTrace();
    4. Now enter this URL string as the URL for the iview.
    5. Do a normal portal navigation to this iview on-click of the button.
    Regards,
    Satyajit.

Maybe you are looking for

  • Re: Move pictures from W755 to PC

    Does anyone know if Verizon has fixed this issue or if Motorola still blocks USB access to the PC? I need to recover some files that were deleted from my W755 and I have a USB cable. I downloaded Motohelper, and P2KCommander as some other sites have

  • How do I convert/merge multiple files (word and PDF) into one PDF?

    I have multiple word docs and PDF files that I need to merge into one file.  How do I do that?

  • Cover Flow image different from

    Most of the time, the album artwork in Cover Flow is identical to that on the thumbnail image in the bottom left corner of my screen (sorry - don't know the correct term for it). However, on occasional tracks they're different. I think I know why, bu

  • Ipad freezes if I try to highlight text when composing mail

    I am having trouble with the Mail application.  When I compose an email, if I try to highlight or select text from one email to copy into a new email, my ipad freezes and I have to exit out of the mail application.  When I open Mail again, everything

  • Immport Failed in Transport studio

    Hi experts, While importing the SAP-JEE.sca, SAP_BUILDT.sca and SAP_JTECHS.sca files in transport studio in CMS I am getting the following error whn importing SAP-JEE.sca file itself. Info:no changes on the CBS request queue (ZES_Test_D) after a wait