Refreshing a region, Rich Region.refresh or addPartialTarget ?

Hi All,
I have a question about refreshing a region.
Assume that a region is bound to a backing bean property (RichRegion myRegion). And getMyRegion() is the getter for the region in backing bean.
What I want to know is the difference between using getMyRegion().refresh(FacesContext.getCurrentInstance()) and AdfFacesContext.getCurrentInstance().addPartialTarget(getMyRegion()). And under which situations, these methods should be used?
Could you please help me telling the difference? Thanks a lot.
Best Regards,
cmoster

Hi,
good question!
1. AdfFacesContext.getCurrentInstance().addPartialTarget(getMyRegion())
This performs a UI refresh of the region, which means the region is only re-rendered. This may not have any impact to the state of the task flow exposed in a region unless the task flow binding has its refresh option set so the task flow re-initializes. You use this option to refresh task flows in regions if you use shared data control (in which case the data content displayed in the region refreshes without the view displayed in the region to change). You can also use this to re-initialize a task flow (which means you restart it so its default activity is executed). You do this by setting ifNeeded as the refresh option and ensuring an input parameter of the task flow binding to be changed. Or, you use the refresh option as "default" but have a refreshCondition EL defined that returns true for a full task flow refresh
2. getMyRegion().refresh(FacesContext.getCurrentInstance())
While 1) is fully declarative, this is programmatic invocation that always refreshes the region such that the task flow exposed therein is restarted (executing the default activity). The method also adds the component to a list of partial refresh targets. This method must be called during JSF INVOKE_APPLICATION phase, which means it is to be used from an action event and not a component event like value change.
Frank

Similar Messages

  • Partially refresh the sql report region by clicking the region selector tab

    Hi,
    In my page i have a region display selector tab. This region selector tab contain show all,booking,service,.. etc. when i click the booking tab,sql report region will appear. My intention is when i click the booking tab i want to refresh that region partially to display the record according to sql query in that region source of report region.
    how to do this?
    skud.

    KevinFitz wrote:
    The report region being displayed is conditional on P2_QUERY item being NOT NULL. I assume the region not appearing is because the Action for the Select List Item is set to None and so P2_QUERY is always NULL.
    No, the region is not appearing because it is conditional on P2_QUERY being NOT NULL. This means that the report region never exists on the page shown in the browser, so it can't be dynamically refreshed. (Dynamic refresh doesn't evaluate region conditions, and it only re-renders the report content, not the entire region.)
    Remove the condition on the report region, check the refresh is working, then reconsider exactly what the requirements here are. If you want the region to appear only when P2_QUERY has a value, and you want it to be refreshed without submitting and re-rendering the page, then the region needs to be hidden rather than conditionally rendered, and shown via a dynamic action when P2_QUERY gets a value.
    I tried adding an additional Set Value True Action for the DA event but got an error as listed above,
    All irrelevant if Page Items to Submit on the region is used properly.

  • Refresh PL/SQL Report Region (not Page) using Select List value

    Hi,
    I've got a report region based on a 'PL/SQL function body returning a SQL query'which gets generated on selecting a value from a Select list item, The Select List action is 'Redirect and Set value' but this causes the whole page to refresh rather than just the report region. I've tried to refresh the report only using a dynamic action on the Select List item (Action now reset to  'None') but now the report is not appearing on choosing from the List. Can anyone suggest a solution that will allow me to refresh this report without refreshing the page? I am using APEX 4.2.2 and the report syntax is as follows:
    DECLARE
      v_statement VARCHAR2(500);
    BEGIN
      SELECT query_text
        INTO v_statement
       FROM sql_queries
       WHERE query_id = :P2_QUERY ;
       RETURN v_statement ;
    END ;
    where P2_QUERY is Select List Item,
    regards,
    Kevin.

    KevinFitz wrote:
    The report region being displayed is conditional on P2_QUERY item being NOT NULL. I assume the region not appearing is because the Action for the Select List Item is set to None and so P2_QUERY is always NULL.
    No, the region is not appearing because it is conditional on P2_QUERY being NOT NULL. This means that the report region never exists on the page shown in the browser, so it can't be dynamically refreshed. (Dynamic refresh doesn't evaluate region conditions, and it only re-renders the report content, not the entire region.)
    Remove the condition on the report region, check the refresh is working, then reconsider exactly what the requirements here are. If you want the region to appear only when P2_QUERY has a value, and you want it to be refreshed without submitting and re-rendering the page, then the region needs to be hidden rather than conditionally rendered, and shown via a dynamic action when P2_QUERY gets a value.
    I tried adding an additional Set Value True Action for the DA event but got an error as listed above,
    All irrelevant if Page Items to Submit on the region is used properly.

  • ADF Region not getting refreshed after Commit

    Hi everyone!
    I'm having some trouble with a region that is disturbing me for more than 2 weeks, its true guys, I tried everything!!
    My parent page is a normal ADF .jspx page that contains inside it a task-flow call. The first task-flow activity is a router, after sending a String
    to router it chooses the region activity that fits the page (in this example I always pass the same value, same String).
    After the router is called then it delegates to "ExecuteWithParams" method call before calling my final region that have its query executed with
    parameter set inside task-flow.
    The region is refreshed (refresh="ifNeeded") when I change row inside a table in ParentPage, all fine here.
    The problem is:
    - After any Commit (with navigation case or executable binding) is issued inside Region the region save its state and does not refresh anymore, even if task-flow parameters change.
    Already tried CacheResults="false" on iterator too.
    I'm using Jdeveloper 11.1.2.1.
    Thanks in advance!!

    Hi,
    so I think the shirt summary of your problem is that an ADF region doesn't refresh after it issued a commit. Sounds like a bug to me if this reproduces in a test case. Do you have a testcase based on the Oracle HR schema ? If so, send it my way in a zip file you rename to ".unzip". My mail address is in my OTN profile. Note that bugs I file are not visible to customers. So if you need to keep track of any state of the issue, you need to file a service request with support yourself.
    Frank

  • Region does not refresh in Address ESS.

    Dear all experts,
    When updating address of employee who belongs to Kuwait country group on web portal ESS, all regions are Kuwait specific and regions do not refresh if employee chooses a different country to update emergency or permanent addresses.
    Can you help on this problem?
    Thanks and kind regards,
    TramNguyen

    You have to create a new address using the NEW button from the overview screen in order to enter a new country within the address screens. You cannot update country within the existing addresses as they screens will not update based on the new country selection. In fact the country should not even be an open field on the screen when in edit mode. If you do not have a NEW button on the overview screen, please check your configuration for subtypes for ESS within the IMG.
    Cheers,
    Mike

  • WIS 10901 error while refreshing report in rich client

    I'm facing a strange issue while refreshing a report from Rich client. Here are details
    Environment: BO XI 3.1 SP3, Oracle application DB. Weu2019ve 2 BO servers (S1 and S2) on cluster and load balancer (common URL) in front.
    While login to S1 with 6400 port, I can refresh report in rich client.
    While login to S2 on 6400 port or using common url, during refresh gives below error u2013
    u201CA database error occurred. Database error text is: (CS) u201CDBDriver failed to load: C:\Program Files\.....\dbd_oci.dllu201D (The specified procedure canu2019t be found) (WIS 10901)u201D
    Iu2019ve installed oracle8i client on my system. Any idea what causing this issue?

    Yes. Oracle 10g client installed on both application server. I've teste the universe connection from server, it's working fine.
    Any idea what could be probable causes of "DBDriver failed to load: C:\Program Files\.....\dbd_oci.dllu201D error?
    One observation, the path of dbd_oci.dll is the BO installation directory of my local machine (on server BO is not installed on C drive). Why it's referring dbd_oci.dll from local client even in 3 tier mode?

  • Not here! Region Tie Regions by Position Change (Logic9)

    I have just upgraded to Logic9 and am looking though the new style instruction manual.
    On the 'Adding or Removing Arrangement Passages' page at the 'remove gaps between regions' part it says Choose Region > Tie Regions by Position Change (or use the Tie Regions by Position Change key command).
    The thing is, that the 'Tie Regions by Position Change' is not under the local menu Region and the KC
    is no where to be found either. Has anybody else seen this at all.
    There is the option 'Trim Regions etc' under Regions though no Tie Regions.
    Thanks
    Message was edited by: ekaton
    Message was edited by: ekaton

    Must be Region > Shuffle Regions left within selection then

  • When I try to change the keyword.url settings in about:config to do a "I'm Felling Lucky" Google search, it just resets to chrome://browser-region/locale/region.properties whenever I restart Firefox.

    I just installed Firefox 4 today. When I try to change the keyword.url settings in about:config to do a "I'm Felling Lucky" Google search, it just resets to chrome://browser-region/locale/region.properties whenever I restart Firefox.

    Start Firefox in [[Safe Mode]] to check if one of the add-ons is causing the problem (switch to the DEFAULT theme: Tools > Add-ons > Appearance/Themes).
    * Don't make any changes on the Safe mode start window.
    See:
    * [[Troubleshooting extensions and themes]]
    See also:
    * http://kb.mozillazine.org/Preferences_not_saved

  • A Region of Regions?

    Hi,
    I'm wondering how to go about creating a page which is a region of regions. So, for example, I have X number of regions to report on per project and Y projects. I'd like the page to do this:
    Y1
    X1 X2 X3 X4
    Y2
    X1 X2 X3 X4
    Y3
    X1 X2 X3 X4
    How can I do this in Apex? I've poked around a bit and it doesn't seem all that easy? Thoughts?
    Thanks,
    Jon

    Joh,
    You are right, this kind of thing can be a little tricky at first. Have a look at this post from Carl and let us know if you have questions:
    http://apex.oracle.com/pls/otn/f?p=11933:30
    Regards,
    Dan
    http://danielmcghan.us
    http://sourceforge.net/projects/tapigen
    http://sourceforge.net/projects/plrecur

  • ListOptions what event is called on refresh?how can i refresh the sessionB

    Hi everyone, i'm currently starting my studies on this platform ...and i'm now going trough some problems that i hope someone can help me out on them.
    I have a project that involves accessing a xml file , and i managed to put some random values of the file on a ListOptions for a listbox.Now i would like to know how can i refresh the session bean or refresh the listbox when i change something on the file?
    Thanks
    DMS

    Hi everyone, i'm currently starting my studies on this platform ...and i'm now going trough some problems that i hope someone can help me out on them.
    I have a project that involves accessing a xml file , and i managed to put some random values of the file on a ListOptions for a listbox.Now i would like to know how can i refresh the session bean or refresh the listbox when i change something on the file?
    Thanks
    DMS

  • Regions within Region

    Hello Everyone,
    Is it possible to create REGIONS WITHIN REGIONS????????.

    Scott,
    Read the login page of my Demo Application.
    Denes Kubicek
    http://deneskubicek.blogspot.com/
    http://www.opal-consulting.de/training
    http://htmldb.oracle.com/pls/otn/f?p=31517:1
    -------------------------------------------------------------------

  • Confirmation in DA before refresh of a PPR region

    Apex 4.1.1.00.23
    I am working with an app that I am upgrading from v3.2 to 4.1.1.00.23 and I have a page/region that had some javascript in it that I am trying to move away from manual JS and into dynamic actions.
    The region in question is a tabular form with PPR turned on and the problem I'm having is that I wish to check if any of the checkboxes are checked and if so, display a confirmation message to the user before the region paginates. I want that if the user does NOT press OK to the confirmation that the pagination is cancelled.
    So I have a DA as:
    1. Before refresh of my region
    2. Conditional based on javascript expression (I have my own JS on the region that checks if any checkboxes are checked and it does work for sure) that checks if at least one checkbox is checked.
    <script language="javascript" type="text/javascript">
    function verifyCheckboxes()
      var checkboxes=document.getElementsByName('f01');
      if (checkboxes==null)
        return(false);
      else
        var vBoxChecked=false;
        for (var i=0;i<checkboxes.length;i++)
          if(checkboxes.checked)
    vBoxChecked=true;
    break;
    return(vBoxChecked);
    </script>
    3. If any are checked, prompt the user with the confirmation "are you sure you want to leave this page?". This action is defined as type "confirm".
    4. If the user presses cancel, the page should not continue.
    Steps 1-3 work fine. Step 4 doesn't happen...no matter what the user chooses (OK or cancel), the region paginates.
    I have worked with confirmations before on "before page submit" and it works like this...cancellilng in the confirmation box cancells the submission. I figured this would work similarly with "before refresh" of a region, but it does not.
    Is this an Apex bug that the confirmation OK/Cancel always allows the region to refresh (different behavior than with a confirmation used before page submit)?
    Ideas on another soution for what I'm trying to do?

    Well I guess the situation is that "before refresh" fires after the signal to refresh the region has been heard by the server.
    In other words, when I paginate through the region, I click the link to paginate, it wants to refresh but encounters my DA that fires before the region actually refreshes. This is fine. My code fires correctly and prompts "are you really sure...?". Problem is, the answer from the confirmation is ignored (either OK or cancel permits the pagination to continue).
    When I've used a confirmation with a "before page submit" in this same manner, answering "cancel" to the confirmation would also abort the submit process.
    So I want the same sort of "cancel" action to abort the region refresh in this case, but seems like it's ignored.

  • Problem doing partial refresh (pull) of HTML region

    In my application, I have a page where on the left I have a list of documents and, on the right, selected document in PDF format.
    The right region is defined as HTML:
    <object id="DataPDF" data="f?p=&APP_ID.:18:&APP_SESSION.:APPLICATION_PROCESS=odp_show_doc::::" type="application/pdf"></object>The function odp_show_doc gets PDF document from a web service and returns a PDF BLOB that fills the region.
    However, to refresh the region with valid document data, I have to resubmit the page each time the user selects a new document.
    To refresh the page partially (only the PDF region), I have tried to use Carl Backstrom's example (http://apex.oracle.com/pls/otn/f?p=11933:48) to pull the PDF content from another page, but to no avail.
    I have defined another page (2) with a region that does the job. When I go directly on that page, I see the PDF region filling. But when I try to pull the same page with the code
    var gReturn;
    var get=new htmldb_Get(null,html_GetElement('pFlowId').value,null, 2);
    get.addParam('P0_NUM_DOC_GED', numDocGed);
    gReturn = get.get(null,'<htmldb:BOX_BODY>','</htmldb:BOX_BODY>'); 
    alert(gReturn);I get the following error:
    <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML2.0 EN">
    <html>
       <head>
          <title>404 Not Found</title>
       </head>
       <body>
          <h1>Not Found</h1>
          <p>The requested URL /pls/apex/wwv_flow.show was not found.</p>
       </body>
    <html>In this case, the odp_show_doc is never called (I have added some debug info in this ODP function).
    Has anyone an idea of what I am doing wrong and what correction should I do to make this pull work?
    Thank you.
    Igor

    Well... It seems to work directly on the machine, if I use the following URL when calling the application:
    http://localhost:8080/apex/f?p=120However, when I call the application from outside with the URL
    https://app-url/pls/apex/f?p=120, pulling the region based on on-demand-process results in:
    The requested URL /pls/apex/wwv_flow.show was not foundPulling an ordinary report is OK.
    Igor

  • Detail region does not refresh when selecting from a drop-down list in master region

    I am using DW CS3 and have updated to version 1.6.1 of Spry.  Using an XML dataset, I am able to create a Spry table as the master region that links to a detail region that displays a small JPG graphic.  It works fine in this format (clicking on a row displays the correct graphic).  However, my table has 80 rows and requires the user to do too much scrolling. So I changed the master region to a drop-down repeat list, but the graphic does not change when a new selection is made in the drop down list.  Listed below is the code produced when I used the insert Spry Repeat List.  I got the same results when adding a spry:setrow="dsChartNurse".  I also tried -- onclick="dsChartNurse.setCurrentRow('{ds_RowID}');" -- which again made no difference.
    When I removed children from the spry:repeat, the master region displayed as a two column list of all 80 items in a drop-down list format.
    <div spry:region="dsChartNurse">
           <select name="select" spry:repeatchildren="dsChartNurse">
             <option value="{name}">{name}</option>
           </select>
    </div>
    <div id="image" spry:detailregion="dsChartNurse">
       <img src="{dataimage}" align="center" style="margin:50px 0 0 0"width="320" height="164" />
    </div>
    Thanks so much to anyone who can help correct my code in order to have a drop-down list display information correctly in the detail region.

    Thanks for the quick reply.  I did solve the problem I was having by changing from onclick to onchange in the master region.  But, now I have another problem with, of course, IE.  I just put in online at http://www.minursemap.org/ageDistNurse.html.  When opened in IE, the drop down list displays the last entry, but the image is for the first in the list.  Thanks again for your help.

  • Form refresh issue inside dynamic region

    Hi
    I have a problem with dynamic region. I have a menu on left side containing two buttons and dynamic region on right side. On clicking one of the button employee form open inside the dynamic region but I am unable to navigate between records by clicking form first , next , previous or last buttons.

    I am new learner of Jdeveloper. I run this tutorial http://baigsorcl.blogspot.com/2010/06/working-with-dynamic-regions-in-oracle.html. I am able to learn about how to dynamically bind the taskflow id. When I click the form button on left side of menu Employee Form open in right side of splitter but its navigation button are not working.

Maybe you are looking for