Handle Portlet event from portal.

Hi all,
I wander that we can handle a event is issued by portlet in the portal?
Example: when I click a command-Link on the portlet, then portal can catch some info of this action I did in the portlet.
Do you have any idea about it?
Thanks a lot!
Edited by: AS84 on Oct 26, 2012 8:26 AM

Hi again.
I'm busy at the moment but you have to follow this steps:
As Producer side (your Portlet):
- Click on your ADF Component (CommandLink or CommandButton) that you want to generate an event.
- In Properties Inspector you'll see "Contextual Events" pane. Select in "+" and add new Event.
As Consumer side (your portal page):
- Generate a class called EventCosumer or something similar to handle events.
- Create a method to handle your event: For example
   * Metodo manejador del boton pulsado
   * @param customPayLoad El texto del boton pulsado
  public void handleButtonEvent(DCBindingContainerValueChangeEvent or String customPayLoad) { // It depends of the payload of you want to share
    // Take that you want of value passed
  }- Generate a DataControl from your EventConsumer Java (Right click -> Generate Data Control).
- Create a methodAction binding in your pageDef.
- In your pageDef in Contextual Events tabs, subscribe your pageDef to the event generated by EventConsumer.
This is basically the steps to do all programmatically. Remember that you can subscribe and consume payLoad values in Runtime too :).
Regards.
Reference links:
- My own blog entry (Spanish): http://www.danielmerchanoracle.blogspot.com.es/2012/05/adf-11g-eventos-contextuales.html
- Frank Nimphius ADF sample about Contextual Events: http://www.oracle.com/technetwork/issue-archive/2011/11-may/o31adf-352561.html
- Yannick Ongena Blog entry: http://yonaweb.be/inter_component_communication_between_taskflows_adf_and_webcenter
Edited by: Daniel Merchán on 29-oct-2012 10:43

Similar Messages

  • Handling SAP Events from CPS

    Hello ,
              is there anyway can we handle SAP events from CPS  , our scenario is if we schedule a job in SAP from CPS , the job in SAP is firing an SAP event based job , how can we get the status of event based job from SAP to CPS.
    Regards
    Raghu

    Hi Raghu,
    There are a few options here.
    You could monitor the SAP event based job in CPS, to see the status.
    You could also create the SAP event based job from CPS, then it is automatically monitored.
    The best would be to verify if you can simply put the two jobs in a CPS job chain. If the second job only waits for the event and does not do anything with the message of the event, this should be very easy. If the ABAP programs involved are custom developments, you could remove the event dependency and replace it with a CPS job chain too.
    Regards,
    Anton.

  • Best way to handle an event from WaitForSingleObject

    Hello LV experts,
    I would like to know what's the best way to handle an event which I catch using the Win32 API (WaitForSingleObject) in Labview(7.1 or 8.20).
    I know there is too many possibilities to do this, but I want to do it  on the best way. that is why I would like to have ideas and tips from you.
    Any and all tips appreciated

    You can download the Library from this link. Inside is an example that shows how to handle windows messages/events.
    http://zone.ni.com/devzone/cda/epd/p/id/4394

  • Event structure doesn't handle all events from external DLL source

    Hi!
    I use a DLL, wich handles an USB CAN transceiver device, and generates LabVIEW user events with extcode.h and PostLVUserEvent() function.
    In my vi I use an event case structure to handle theese external events. The problem is, that if the events come too frequently, then it cannot handle all events.
    The vi contains a couple of parallel while loops which process the incoming data from the external event.
    In another application I use the same architecture, and that works fine. This one is more complex.
    Do you think I have reached the limits of the program? Or what else can be the problem?
    I have tried to use a queue in the  event structure, it helped a little, but yet, not all the events are handled. My external DLL sends all event, so the problem is not there.
    Thanks in advance!

    Hi Wasz,
    Thanks for the post and I hope your well.
    It is not possible for the event structure to miss events - it simply queues them up. To keep the event structure 'in time' with the code you must ensure the code to execute in each event is minimal to allow the event structure to handle the next event. 
    Please see this two links:
    event structure buffering: leading to,
    How to avoid built-up for "cursor move" events? : where somone is trying to avoid handling all events.
    What sort of events are not being handled? Could it be an issue your events are not configured correctly? Maybe if you could produce a small example in LabVIEW code, so we can just test the event structure configuration... someone working around the external dll call - which you seem sure is working correctly.  
    In terms of queuing to process the events in other loops is certainly an option to speed up the event structure. To do this, use a produce/consumer design pattern.
    hope this helps,
    Kind Regards
    James Hillman
    Applications Engineer 2008 to 2009 National Instruments UK & Ireland
    Loughborough University UK - 2006 to 2011
    Remember Kudos those who help!

  • Portlet Information from Portal

    Hello,
       I'm developing a non-SAP portlet that will be consumed by the portal and was wondering what information, if any, the portlet will have access to from SAP.  Basically I am wanting to know if I will be able to get any information about the user that logged into the portal.
    Thanks,
    Brandon

    Simon,
       I've been looking into how to extract the user id from the SSO Ticket.  I found where I need the SAPSSOEXT stuff, but this seems to be just a patch to the SAP system.  My application will be on an external java server and thus will not have access to the libraries that this patch contains.  Do you know of a way for me to get the necessary libraries, such as in a .jar, so that they can be accessed on the external server?  Or can the SSO Ticket only be accessed by an application on the same server?
    Thank you for your assistance.
    Brandon

  • Portlet disappeared from Portal Builder after editing

    I created a Master-Detail form in portal builder. At the end of one edit, I clicked cancel to undo the change. Somehow, the portlet was totally disappeared. I checked the repository table WWA_FORM$ and WWA_MODULES$, this form is still there, but it just does not show up in the portal builder navigator page. Can anybody help me to explain this abnormal behavior and how to get the form back to the builder?
    Thank you for your help.

    I did more research and found out that the form module that was missing is not in the table WWV_modules$. I am wondering why Oracle portal created such an inconsistancy. The module is still in wwa_modules$ table, but not in wwv_modules$ table. How did the record get deleted from wwv_modules$ table, but not wwa_modules$? I am the only user of this thing and I never delete this module. All I am doing is editing. Anybody has any ideas?

  • How to handle Lov event from Advanced Table

    hi all,
    I have requirement like I need to return 5 items from lov RN and need to bind them with curresponding 5 coloumns in advanced table which is diplaying fine,
    but once clicked on 'Add New Row' button values from the privious row is getting null/disappearing. All the items in advanced table are binded with proper view Attribute.
    Please let me know why it is behaving so? and kindly give the solution also how can I handle this.

    Hi,
    The columns on which you are returning the values must be messageStyledTexts Right??
    If yes, then you should know that read only fields are not able to hold values and hence the lov mappings gets lost when you click on Add New Row button.
    To avoid this.
    For 5 columns, create 5 form Values and bind the same View Attribute to them as to the columns.
    Now in the LOV also create 5 mappings for form values same as you have created for table columns.
    This way it should work.
    Thanks,
    Gaurav

  • Portlet minimization from .portal file

    i'm using 8.1 sp2.
    I have a portlet that I would like minimized always. I can open up the portlet and designate it as such through the default minimized=true and it works.
    however, when i try to accomplish the same feat through the portal file, it doesn't work. i check the xml in the portal file and indeed it does designate that instance of the portal as minimized. however, it doesn't do it upon rendering.
    in this scenario, i need to do it through the portal if possible because that same portlet appears on several portals. and only on one portal do i want that portlet not to appear.
    outside of some programmatic logic statement, what should I be looking at?
    Thanks,
    -Andy

    i just tried this in sp4 and it worked fine.
    I think i recall a bug about this a while back that was fixed in one of the service packs
    Chris Jolley
    Portal Architect

  • How to Handle events from audioplayer by ADF ObjectMedia Component

    Hi,
    In My application Having a ADF ObjectMedia Component for the audio play,
    My requirement is to handle the events from the Player,i.e Need to get an
    event when the user pause the player,can i get the event in backing bean.or else please help me in any other way to get the requirement asap.
    Thanking you....

    Hi,
    assume the media player most likely is a browser plugin. Question: Does the media plugin raise events ?
    If the media player has a JavaScript API that allows you to call a JavaScript function then you found a gate open to publish the event to the JSF application
    So as a todo for you: Check with the media player vendor if there exist a JavAScript API or any other sort of eventing.
    Frank

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

  • Calling Portal event from ABAP class

    Hi Experts,
    I need a following clarificatrion, Please help,
    1. Is it possible to call a webdynpro method from a normal ABAP class?
    2. If no, we need a functionality of a class 'CL_WDR_HTTP_EXT_MIME_HANDLER' having method 'DO_DOMAIN_RELAX_HTML'.
    Is there any alternative method which can be used in ABAP having the same functionality.
    3. Is there any ways with which we can call portal event from ABAP class?
    Thanks,
    Shabir

    >1. Is it possible to call a webdynpro method from a normal ABAP class?
    I wouldn't necessarily recommend this approach. You shouldn't try to trigger events or any of the standard WDDO* methods from outside the WD Component itself.  That said, you can pass the object reference (like the WD_COMP_CONTROLLER object reference or the View Object Reference) into methods of normal classes.  Be careful if you are finding yourself calling a lot of your added methods from outside WD.  This is probably a sign that these methods should be in the Assistance Class or some other Class functioning as a Model Object.
    >2. If no, we need a functionality of a class 'CL_WDR_HTTP_EXT_MIME_HANDLER' having method 'DO_DOMAIN_RELAX_HTML'.
    Is there any alternative method which can be used in ABAP having the same functionality.
    What exactly do you want to do here?  Do you just want to get the relaxation script?  For what purpose?  You should never need to inject the relaxation script into WDA. 
    >3. Is there any ways with which we can call portal event from ABAP class?
    To what purpose.  Do you just want to delegate the triggering of the event that is inside WD Component to be called from a class?  If so you can pass the portal API object reference into a class from the WD Component.  However this only works while running within WD.
    How is this class used?  Are you running in WD?  Are you trying to generate some HTML code that runs in the portal independent of WD?

  • 8.1 equivalent of portlet:form event=bea.portal.framework.internal.refresh

    I've got a portlet with an edit JSP that allows the user to set some portlet settings. The edit JSP uses a form defined with the tag <portlet:form event="bea.portal.framework.internal.refresh" >. This in essence allowed the edit JSP to submit the form to itself, so it could then process (store) the settings.
    This tag is no longer supported in 8.1. I haven't been able to find what the equivalent is. Am I going to be able to do the same thing, or am I going to have to rewrite the Edit piece as a page flow?

    I've already tried that and it's not working in my current portal.
    The other things I've tried are <render:postBackUrl/> and <render:windowUrl> for the form action, and they weren't working, either. But since then I've discovered that in a new vanilla portal installation, the <render:postBackUrl/> action works fine (I assume the controller would, too, but I didn't try it).
    It seems I now have a different problem to work through to figure out why <render:postBackUrl/> works in a new installation, but not in my current one. The same goes for the controller.

  • Dispatch custom event from itemClick handler

    hi,
    I'm trying to dispatch a custom event from my itemClick handler.
    So when I click on an item of my datagrid, I want to send a custom event.
    private function dataGridItemClickHandler( event:ListEvent): void
         dispatchEvent( new myEvent( myEvent.NEW, values[event.columnIndex]["name"]) );
    <mx:DataGrid dataProvider="{values}" itemClick="dataGridItemClickHandler(event)">
    </mx:DataGrid>
    but this code doesn't work.
    Can you help me
    thanks
    best regards

    Please see that you override the function clone() and return the new function.If that is correct.you can call the super() method to initialize your base class.
    If your custom event {myEvent} is in package say: CustomEvent,
    1)import package CustomEvent.myEvent
    2) keep in <mx:metadata>[Event(name="NEW", type="CustomEvent.myEvent")]</mx:metadata>.. name suggest  what type of event you want
    3)Create an itemclick listener and in dataGridItemClickHandler
    private function dataGridItemClickHandler( event:ListEvent): void
         dispatchEvent( new myEvent( ' NEW ', values[event.columnIndex]["name"]) );
    private funcation myEventListener(evt:myEvent):void
    //Put your logic
    4)Use this event by name NEW="myEventListener(event)"  this will behave as event type in the datagrid tag like click, hover and others.
    Hope this helps! Please excuse if anything is logically incorrect.Do point out.Thanks.

  • How can i download file from a pageflow portlet in Webloigc Portal?

    How can i download file from a portlet in Webloigc Portal?
    My Question is, when i download files used codes in a pageflow listed below,
    it didn't work. but in non-portal environments, it worked well.
    How can I download a file from a portlets in portal??
    Thx in advanced.
    this.getResponse().setContentType ( "application/ms-excel" ) ;
    this.getResponse().setHeader ( "Content-Disposition" ,"attachment;filename="
    +new String("Excel.xls".getBytes(),"iso-8859-1")) ;
    sth.write(this.getResponse().getOutputStream());

    i always use an old fashioned method when i have to do this, i create a new jsp that contains a scriptlet that writes to the ServletOutputStream.
    <i>outputWriter.jsp</i>
    // define your own class to get file here, otherwiser use netui-data:callControl tag
    <code><pre>
    File file = FileControl.getFile(fileName);
    String fileName = (String) request.getParameter("fileName");
    response.setContentType(file.getContentType());
    ServletOutputStream sos = response.getOutputStream();
    InputStream is = file.getInputStream();
    for(int i = 0; (i = is.read()) != -1;)
    sos.write(i);
    sos.close();
    </pre>
    </code>
    i then call this jsp from the jsp to which i forward in my action using a simple url rewrite with file name on the url.
    <a href=outputWriter.jsp?fileName=nameOfFileToDownload                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • Query- IPC using JSF Portlets in WebLogic Portal

    The question is how to pass data when doing InterPortlet Communication using Local JSF portlets in Weblogic Portal.
    I will eloborate on the particular scenario we have below.
    Two JSF portlets are build (both are not using Java Page Flows). The first porltet has a table of data. When the user clicks on one of the items in the table (which is coded using <h:commandLink/> option), the second portlet should show some details on the item clicked.
    For example:
    If there is a list of books in first portlet, when clicking on one of the book name, the details of book should come up in the second portlet.
    To achieve this, faces event was enabled in first portlet with requestAttrPersistence option set to session.
    For example :
    <netuix:content>
    <netuix:facesContent contentUri="/bookList.faces" requestAttrPersistence="session">
    <netuix:facesEvents>
    <netuix:facesEvent action="/bookDetails.faces" eventName="bookDetailEvent"/>
    </netuix:facesEvents>
    </netuix:facesContent>
    </netuix:content>
    The second portlet was configured to handle faces events, particularly the bookDetailEvent.
    Example:
    <netuix:handleFacesEvent eventLabel="handleFacesEvent1" eventName="bookDetailEvent" fromSelfInstanceOnly="false" onlyIfDisplayed="true" sourceDefinitionLabels="JSFPortlet_1" sourceDefinitionWildcard="this">
    <netuix:invokeFacesAction action="/bookDetails.faces"/>
    </netuix:handleFacesEvent>
    Going by this method, how can we find the particular book whose detail has to be shown? As in JSF, we dont directly access the request attributes, what is the ideal way to pass data from one page to other?
    Please help on this.

    i am also having the same problem.I tried by passing _nfls=false but it didn't work.Can you suuggest where do i need to set this or any other parametrs such as this programmatically?                                                                                                                                                                                                                                                                                                                                                                           

Maybe you are looking for

  • Check if field has value 0 - zero value on field

    Hi, I've got the following code: DATA: v_qtd TYPE i. SELECT-OPTION s_qtd FOR v_qtd. I'm using a Z table Z001 and there's a numeric field there that's filled with values >0 (greater then zero). If I have 6 materials and only 4 have the field QTD with

  • Error encountered when saving a query

    hi, I created a new query in the development system and while saving it i get an error the query cannot be saved due to problem in transport,Bex transport request is nto available,choose teh existing request. I did create atransport requests and trie

  • Can't see brand new iPod Nano in Windows!!!

    I just bought a brand new iPod Nano (2nd Gen) for my daughter for Christmas, and right out of the box it would not be recognized by Windows XP or iTunes -- even though another iPod Nano (1st Gen) that we own did connect. It was charging though. I use

  • How to know the limit of a column on a page in iSupplier

    Hi All, Suppliers are facing a issue where they are not able to see all invoices for a payment. iSupplier page just shows the first 400-500 invoices and rest are not shown. This page seems to be oracle seeded page, How can I check which element is re

  • RE: "Unable to create font" After Effects CS 5 won't launch

    My spanking new After Effects CS5 won't launch due to "Unable to create font" error. I'm running OS X 10.6.3 on a 17" with specs listed below. After Effects CS3 is running fine. What's the solution? Model Name: MacBook Pro   Model Identifier: MacBook