How to publish contextual event from dynamic region

Hi Experts, plz help.
Scenario :
I have a page , say Page A.
I have two bounded task flows, say HeaderTF and LinesTF.
HeaderTF is placed as a static Region in page A and LinesTF is a dynamic region in page A.
LinesTF has a table with Amount Column.
HeaderTF has a text field which shows the total of amount column.
Requirement :
when user adds new rows or changes existing rows or deletes any rows in LinesTF, total field in HeaderTF should be updated.
On change of amount value in lines, I am calculating and updating the total attribute of header VO as all of them are sharing same DC.
but the value is not reflecting becos partial triggers cannot be kept for total field.
So I am using contextual events.
I created a contextual events for amount field, delete button and table as well (In LinesTF).
and I created handler method in AM which calculates total and dragged it as a text field in HeaderTF.
Now when I am trying to subscribe from pagedef of pageA, i am able to find the handler which is created in HeaderTF but could not find any contextual events in event lov.
Question :
1. Is my approach correct?
2. Cant we publish contextual events from dynamic regions?
3. Is there any alternate way of achieving this?
I did not try refreshing HeaderTF by passing input params because I dont want the entire region to be refreshed.

Try creating the event mapping - please see "28.7.2 How to Create Contextual Events Manually" in Dev Guide http://download.oracle.com/docs/cd/E15523_01/web.1111/b31974/web_adv.htm#CACJBFGI

Similar Messages

  • How to create contextual event with custom payload?

    I use the following code to invoke contextual event from my region via the "action-listener" of a command-link:
    <af:commandLink text="#{row[def.name]}" id="cl1"
    styleClass="tableLinkActive"
    actionListener="#{backingBeanScope.PanelToConveroFormManager.handleSelectedRow}">
    The following "action-listener" is designed to pass the current selected record key to the "consumer" of the contextual event:
    public void handleSelectedRow(ActionEvent actionEvent) {
    String currentRecordKey = getCurrentRecordKey();
    JUEventBinding eventBinding = (JUEventBinding)BeanUtils.getBindings().get("RefreshParentEvent");
    if (eventBinding != null) {
    ActionListener actionListener = (ActionListener)eventBinding.getListener();
    actionListener.processAction(actionEvent);
    How do I pass the "currentRecordKey" value as a custom "payload" via the event-binding "RefreshParentEvent" in the above code?
    Is there any code example on using contextual event with custom payload?

    Hi,
    the custom payload is referenced when you set up the event itself. You use EL in the custom payload definition to point to a managed bean method that when called accesses the current rowKey. The Java code you show just passes the ActionEvent of the ADF Faces command button and invokes the event. It does not manipulate the event definition.
    <eventBinding id="eventBinding"
                      Listener="javax.faces.event.ActionListener">
          <events xmlns="http://xmlns.oracle.com/adfm/contextualEvent">
            <event name="testEvent"
                   customPayLoad="#{mymanagedBean.rowKey}"/>
          </events>
        </eventBinding>Frank

  • Programmatically publishing Contextual Events

    Does anyone know whether there is a programmatic way of publishing contextual events? The usual route of course involves invoking an operationBinding or updating an attributeValueBinding, but those seem some what complex ways of publishing an event if you would want to do so from for example a serverListener or some other part of managed bean logic.
    thanks.
    Lucas

    Lucas,
    Below is an event producer binding and the code that invokes it from an ADF Faces button. If you call the same from a managed bean then you need to create the
    ActionEvent manually before you invoke it
    <eventBinding id="MyEventBinding"
       Listener="javax.faces.event.ActionListener">
       <events xmlns="http://xmlns.oracle.com/adfm/contextualEvent">
         <event name="mActionEvent"/>
       </events>
    </eventBinding>
    public void onEmployeeSelect(ActionEvent actionEvent) {
      BindingContext bctx = BindingContext.getCurrent();
      BindingContainer bindings = bctx.getCurrentBindingsEntry();
      JUEventBinding eventBinding = null;
      //get a handle to the eventBinding
      eventBinding = (JUEventBinding) bindings.get(“MyEventBinding”);
      ActionListener al = (ActionListener)eventBinding.getListener();
      al.processAction(actionEvent);
    }Frank

  • How can I remove events from my iPhone. I want to delete all the events from my iPhone.

    how can I remove Events from my Photo in iPhone

    Connect to computer iTunes and uncheck under Photos > Events then do a sync.

  • How to raise an event from a program

    Hi,
    I am creating a workflow for HR, the person will request a basic pay change than, this will start the workflow. For this i am making a screen from where i need to triger the event for the workflow.
    Does anybody has any idea? of how to raise an event from a program. or has anybody worked on a scenario like this
    Khusro Habib

    You can also use the FM SAP_WAPI_CREATE_EVENT which is a little newer I think. (I don't have access to a system today so that may not be the exact name of the FM but if you search SE37 under SAPWAPIEVENT* you should find it.
    the parameters will be the event name, and the object key.  The object key will be the key field of the workflow object you are using. 
    For example if you were using the saled document object then the object key would be the sales document number.  Carefull how you enter the object key, it can be a little tricky on whether or not you need the leading zeros in the input parameter. 
    Hope this helps.
    Brent

  • How to subscribe contextual event rised in a Dynamic Region

    Hi all,
    i can subscribe contextual event rised in a region.
    but when it comes to Dynamic Region, i cannot find available contextual event in the "Select Contextual Event" dialog.
    Is there a way to subscribe contextual event rised in a Dynamic Region?
    Thanks

    Hi,
    for dynamic regions you don't subscribe to a contextual event producer but only the event name (which you type in). The producer name will then be wildcarded '*'. The visual dialog will shows <Empty> by default, indicating a wild card provider.
    Frank

  • Apply request values from a region on an event from another region

    Hi,
    I am quite new to ADF and that's my first question/post here (and as a matter of fact pretty much anywhere),
    so i hope i manage to make my problem clear enough.
    First i am using ADF Faces + ADF BC using JDeveloper 11.1.2.1.0 with the integrated WebLogic Server
    Now the what is the case:
    I have a page with two af:regions in it.
    The first one is basically a single selection table.
    The second one is a to put is simply an edit form for the selected row of the first table.
    I don't use the contextual events mechanism ( i have spent some week or more playing around with it awhile ago, but from that exprience i don't recollect any particular thing that might solve my problem) so what i do is pass as parameter to the first(table) region a "delegate" that would listen/handle selection events and in the backing bean of the table i have the selection listener that fires the events/calls the delegate's handleEvent(String eventType,Object data) method so that the main page knows and refreshes the second/edit form region
    with the newly selected ID of the entity.
    My problem is that if i had entered data in the form in the second region it is lost after selection
    has been made in the first one.
    I see (in the http request content of the selection event, or in the requestMap), that all that was in the html page, including the second region is transmitted to the server - so are the newly entered values. However the jsf components that are a part of the second region are not applied with their new values, nor their model is updated in the next jsf phase.
    Now I suspect that has something to do with the (Adf)RichRegion being a EventRoot or something.
    I tried putting partialTrigger to the second region (though i currently and for various reasons call the AdfFacesContext.addPartialTarget programmatically at about one million places in the java code after the selection event)
    I even tried hacking the javascript AdfRichRegion object, so that it would always return false if asked isEventRoot. :) that's how desperate i was
    The only solution i have so far is:
    First to make clear. When i say refreshing the second region i don't mean calling RichRegion.refresh(), but rather RichRegion.queueActionEventInRegion(....., "refresh",PhaseId.ANY_PHASE) which in the second's region taskflow is just a method call, that sets the right current row of the iterator and then loops back to the same (one and only view in this taskflow - the edit form) and adds some parialTargets to the AdfFacesContext, so we see the new data
    then in that methodCall (which i think happens in the INVOKE_APPLICATION phase) i add those few lines to make sure the values are applied to the jsf components sub-tree of interest:
    RichPanelGroupLayout fl = getFl();//that's a binding of the UIComponent, that holds all the inputTexts i care about
    fl.processDecodes(FacesContext.getCurrentInstance());
    fl.processValidators(FacesContext.getCurrentInstance());
    And when i say make sure that the values are applied... i actually mean - get on my knees and pray because the whole thing looks too hacky already, but so far it works.
    But now i have to make sure the validation has been ok (otherwise i get a funny effect of seeing the red popups at the invalid text inputs just for a second and then my region is refreshed to the new entity or i get an JBO exception depending of whether i call the next lines that follow without the if(..){processUpdates}
    How do i check this:
    System.out.println(FacesContext.getCurrentInstance().isValidationFailed());
    //The above line would print false nomatter what happenned so i decided to use this "something":
    boolean validationFailed = FacesContext.getCurrentInstance().getMessageList().size()>0;
    if(validationFailed){
    //dont update the iterator's current row and return to the edit form page
    return "fail";
    }else{                    
    fl.processUpdates(FacesContext.getCurrentInstance());
    //update the current row and return to the edit form page
    It took me days to come up with this...i would call it hack...And a day or two more to adapt the rest of the page's logic with the whole design changes i had to make but i still believe there must be some better solution that i am missing because for a number of reasons i don't feel right eith this one, which, while implemented and working (i hope) makes the whole real case a lot more complex than it used to be (and still feels like a hack),
    just for the simple reason that I want to get some updated values back in the model.
    Just as an example of a design change i had to make i give you the afformentioned methodCall i had to add, because the processUpdate would not work if not called with the right adf bindings context... first i tried calling them from a custom PhaseListener i have but at that moment nobody knows what #{bindings.MyEntityId.inputValue} is.
    Thanks and Greeting
    trout
    Edited by: trout1234 on Aug 2, 2012 10:47 AM
    Edited by: trout1234 on Aug 2, 2012 10:57 AM

    Oh yes... and i have also noticed that if the action is triggered from a component(e.g. clicking on a commandLink) that is a part of the main page
    the values are updated in all regions (i think so :) ) ... so i even tried a client listener in the first region that calls javascript function that queues a custom event with a source component from the main page, but yet the selection event is propagated to the server even with the event.cancel() and evt.stopBubbling()
    and i could not make my custom event force the apply request values... but here i might have done somthing wrong i dont know it is a mess anyway... sure this one sound more of a hack than my current option....by my criteria at least

  • How to add Select event in dynamic ALV

    Hi,
    I have created dynamic ALV and now i want to checked the selected row value.
    If in the selected row contain 'A' value then i have to disable the Button given on the screen.
    If in the selected row contain B' value then i have to enable the Button given on the screen.
    How to add the event once I select the row.
    I have done like this . but it is not
    lw_api_2->do_dynamic_navigation(
              source_window_name          = 'ZWDCHHR_EX_TASK_DELE'
              source_vusage_name          = 'ZWDVHHR_EX_TASK_DELE_USAGE_1'
              source_plug_name            = 'TO_ALV'
              target_component_name       = 'SALV_WD_TABLE'
              target_component_usage      = 'ALV_USAGE1'
              target_view_name            = 'TABLE'
              target_plug_name            = 'DEFAULT'
              target_embedding_position   = 'ZWDVHHR_EX_TASK_DELE/VIEW_DELEG_MY_TASKS' ).
      register event handler
        lw_cmp_usage_2->add_event_handler(
           listener        =  lw_api_2
           handler_name    = 'ONSELECT_TAB1'
           controller_name = 'INTERFACECONTROLLER'
           event_name      = 'ON_SELECT' ).
    Thanks and regards
    Amita Gandhi

    Hi Amita,
    You can try fetch the number of the row which was leadselected through R_PARAM->INDEX. (This would be just a normal integer variable. You can try check this out in debugging mode. ) Now you can just read the data of this row from the context node by saying as GET_ATTRIBUTE up on the nodes reference with the index as R_PARAM->INDEX.
    Regards,
    Uday

  • How to get all events from calendar using calcalendar store framework.

    Hello,
    I have two problems with calcalendar store framework programming.
    1. I need all the event which are present in iCal calendar.Event may be present in year 2025 or 2050. and if the event is recurring then i need only one event.
    2. if the event is recurring then i need only one event within the calendar event predicates (start date and end date). I am not suppose to give the occurrence date for event.
    How can I implement this with CalCalendar store framework.
    Thanks And Regards,
    xmax.

    Hi,
    Per my knowledge, there is not a method to get all the recurring events using CAML query in one request.
    Here is a thread with the similar question for your reference:
    https://social.msdn.microsoft.com/Forums/sharepoint/en-US/eed6be6d-c9ff-4d01-80de-8a4b67d3d7a5/use-caml-to-get-all-recurring-events-from-a-calendar
    We can get all the calendar list events at first, then filter all the recurring event from the result set.
    Best Regards
    Dennis Guo
    TechNet Community Support

  • How do I transfer events from one iphoto library to another?

    I have  2 iphoto libraries.  How do I transfer some events from one to the other?

    Either:
    1. Export from Library A to the Finder and then import to Library B - this means you won't get the edit history of the images nor will you get all the metadata
    or
    2. Use iPhoto Library Manager for the job, which will get all versions and all metadata
    or
    3. If you have Aperture, use that.

  • How do I delete "Events from my Mac" from my iPad photo library?

    I usually sync images from Aperture via iTunes. And though I've unchecked all the boxes so that no photos were to be synced, the pad still has a ton of photos that show up in the Events or Moments.
    I've now turned off Photo syncing in iTunes, which should have deleted all the photos, but the pad still has this huge album of images titled, "Events from my Mac". How do I get rid of these images? They're taking up piles of space. I can't trash them as no trash icon shows up. ?
    Help!

    More info:
    So under the iPad preferences in General/ Usage:
    Camera roll = 69.0 MB
    Photo Library  = 7.96 GB ? !!!!
    Photo Stream = 345 MB ? PhotoStream is turned off! ?
    I just don't understand.
    iCloud is turned off on the Mac. It's on on the pad but Streaming is turned off, both personal and sharing.
    In iTunes there are no pictures from Aperture to import or sync.
    So what gives?
    Help!

  • How can i export events from ical to word

    I need to use the description of many events from Ical in a text using Word for Mac.
    How can I do it?

    thisone - Thanks for your response, but unlike most events, this one does not have an edit button before the Event Details screen. In the top right hand corner next to the words 'Event Details' there is just an empty space.
    This event is extremely pesky and I have repeatedly synced my phone in attempt to remove it. It was an invitation I accepted for a recurring weekly event, which was sent to an email address for my old job. That email address is no longer active and no longer existing on my phone, but this event continues to show up on my calendar every single Tuesday.
    Help?

  • How can I remove events from iCal?

    I send myself calendar invites (repeating weekly meeting invites)from Outlook from my office workstation, to my personal email address that I monitor on my iPhone.  These are typically .ics files.  Once I accept that event on my iPhone, then that event shows up on iCal.
    But if I cancel that event on my workstation, I get the cancellation email on iPhone, but the event DOES NOT get removed from iCal.
    How can I remove those events from the iPhone iCal app?
    Thanks!
    Vince in Leesburg

    thisone - Thanks for your response, but unlike most events, this one does not have an edit button before the Event Details screen. In the top right hand corner next to the words 'Event Details' there is just an empty space.
    This event is extremely pesky and I have repeatedly synced my phone in attempt to remove it. It was an invitation I accepted for a recurring weekly event, which was sent to an email address for my old job. That email address is no longer active and no longer existing on my phone, but this event continues to show up on my calendar every single Tuesday.
    Help?

  • How to move 1 field from 1 region to another region of same page persnaliz

    dear friends,
    i m geting some problem reagrding the Oracle Apps personalization. i dont have much more knowledge about personalization of OA Framework. i want to change one field from one region to another region of the same page. can u please guide me regarding this.
    as per my knowledge i have to create the new item from personalization and the bind that item with the view object. but i dont know how to that exactly. i m geting problem to find the name of that perticular view which belongs to that perticular field.
    so can u please tell me step by step how to do that, as i m beginer in this modual..
    thanx in addvance
    shailesh

    Shailesh,
    You can hide (Render = false) for first field in 1 region using personalization.
    You can create new item in IInd region and bind with View Object.
    Question : I m geting problem to find the name of that perticular view which belongs to that perticular field.
    Ans : Check the whether you are able to get ViewInstance and ViewAttribute Name from 1 field.
    Thanks, Avaneesh

  • How I can delete event from calendar (iOS7)??

    How I can delete an event from calendar (iOS7)?? I can't find any icons, any gesture for that!!!

    I've never used the calendar app until I read this, so I created a test event and then spent about 15 minutes trying to figure out how to delete it, but I finally figured it out!  Here's how to do it:
    1) Tap the event to bring up the info panel about it.
    2) Tap "Edit".
    3) A long panel will appear, letting you set all sorts of info about the event, but there doesn't appear to be any way to delete it, but...
    4) Pull up on that long panel, and way down at the bottom is a red "Delete Event" button.  Tap it and confirm the deletion in the message box that appears, and the event it gone!
    Ken

Maybe you are looking for