Topic
  • 3 replies
  • Latest Post - ‏2012-12-07T15:44:06Z by mburati
SystemAdmin
SystemAdmin
9029 Posts

Pinned topic Co operative source action in main action list and on Page load event

‏2012-12-04T12:11:20Z |
HI,
I need to do some thing like this,

a page has two portlets, one portlet will send a value and other will recieve the value and based on the value it will display result...all should happen while page loading.
im doing something like this in source portlet
in the main action list,first im sending the value and then displaying the page

Action List:
pb286Action_appLinkSourceAction
page1

if i do like this im getting the error : specified page main doesn't exist.

am i missing anyhting?

Thanks,
Updated on 2012-12-07T15:44:06Z at 2012-12-07T15:44:06Z by mburati
  • mburati
    mburati
    2568 Posts

    Re: Co operative source action in main action list and on Page load event

    ‏2012-12-04T15:49:02Z  
    The main doesn't exist sounds like there may have been a regen error in that model (check the deployed WAR's WEB-INF/logs/event.log for errors during regen).

    I believe the jsr286 portlet specification says that events are sent from processAction or processEvent, thus during an ActionRequest or EventRequest, and not during a Render request which is what you get the first time a portal/portlet page renders, so you may be trying to send an event at the wrong time.

    There are at least a couple of other ways to accomplish what you're trying to do here, if you're trying to pass data from portlet 1 to portlet 2 on render, as opposed to on action from the user in the browser:

    1) Use a WEF Shared Variable to set a value in portlet 1 that portlet 2 then looks for.

    2) Use jsr286 Public Render Parameters (search this forum and the WEF Wiki for more on "public render parameter" ).

    I hope that info helps,
    ..Mike Burati
    http://www-10.lotus.com/ldd/pfwiki.nsf/
    The postings on this site are my own and do not necessarily represent the positions, strategies, or opinions of IBM.
  • SystemAdmin
    SystemAdmin
    9029 Posts

    Re: Co operative source action in main action list and on Page load event

    ‏2012-12-06T14:49:45Z  
    thanks Mike for the reply,

    here the problem is we don't have the controle over the second portlet, it came with the Software bundle (IBM Forms experience Builder),
    if we give the URL, it simply shows the form, and it accepts only through the Events and wiring.

    Thanks,
    Saikiran V
  • mburati
    mburati
    2568 Posts

    Re: Co operative source action in main action list and on Page load event

    ‏2012-12-07T15:44:06Z  
    thanks Mike for the reply,

    here the problem is we don't have the controle over the second portlet, it came with the Software bundle (IBM Forms experience Builder),
    if we give the URL, it simply shows the form, and it accepts only through the Events and wiring.

    Thanks,
    Saikiran V
    Ok, it sounds like you do need to send a wired event then, but to do that, I believe it has to be sent from an action in the first portlet, and not from the first render of the first portlet as far as I know.

    So one option is to have the user click on something in the first portlet (eg, on intro page?) that fires the event to the second portlet. If you really need to have it happen without user intervention, then you may be able to use Javascript (eg, either Timed Action or hand coded JS) that does an onclick of the link or button that would otherwise fire the event for the user (hiding the button/link with css if you need to). Just be sure that it doesn't end up getting into a loop of firing it repeatedly every time the page re-renders due to the event being fired to the other portlet (eg, only have that JS on the very initial page of the first portlet and after it fires it, get it off the page of the first portlet so it won't keep firing it every time the portal page is re-rendered for some reason).

    I hope that info helps,
    ..Mike Burati
    http://www-10.lotus.com/ldd/pfwiki.nsf/
    The postings on this site are my own and do not necessarily represent the positions, strategies, or opinions of IBM.