Sorry I forgot that it does use auto update solution does use the html_PPR_Report_Page function but rember this is specifc for reports because it fasttracks to the report engine without going through the whole page layout and condiitons logic.
That being said.
There you go.
Very slick! Thanks.
"Use the PPR template for the report and change the header section"
Also, if I use the PPR report template, the region header already has all the stuff in there, right? So I dont need to put that in myself, do I?
At some point the report id needs to be provided you could easily make it a js variable in the page instead of hardcoded into the js.
The htmldb:href link and id on the report table need to be added to the report template to make it work.
Instead of refreshing based on time, Can this code be used to refresh upon demand? I see you haven't updated your application export for this, Carl, and I would like to see the back-end of this to try to achieve my result
First let me thank you for all your help, your insight has proven invaluable in what I am trying to do. This "report refresh" , can it be used to display a report based on a value in a text box w/o a submit (like I was trying to do here unsuccessfully) http://htmldb.oracle.com/pls/otn/f?p=27948:4
And just a reminder if you can get the application export up soon.
I got the partial page refresh working, however, it does not update based on my text field. Tried fixing the URL in the PPR region to use the value of the text box, still can't get it working, any ideas on how to implement this???
Yes thats not going to work. The auto refresh code is directly tied to the pagination code it expects a report to already be in the page, and then fast tracks to the report engine instead of going through page logic.
I'll have an example for you in next day or so.
Here's the example.
I'm working up all the howto code right now probably be up by tommorow. I'll also be putting up a new export of my app tommorow.
All the code is on the page now. http://htmldb.oracle.com/pls/otn/f?p=11933:48
So basically this is just a slight variation on using an application process but instead you are pulling a region on a page.
This example contains 2 pages page 48 which is the visible page and page 47 which contains the SQL report.
Page 47 has a special page template that has most extraneous html removed basically your going to be pulling the whole page even though you are only going to use a small section, (this will be greatly simplified/improved in future HTML DB version) so you want the page template and region templates to bare minimum. In this example the region doesn't even have a template assigned.
Pulling the whole page has the disadvantage of pulling much more html across the wire than you need but as the advantage of allowing you to use all standard HTML DB page functionality, computations,process,conditions,templates so there is a trade off.
If you are only interested in speed you could use an ondemand process in much the same way and build your own report.
var get = new htmldb_Get(null,&APP_ID.,null,47);
When using with an application process you usually go to page 0 here because we are grabbing a substring of page html we are going to page 47
gReturn = get.get(null,'<htmldb:BOX_BODY>','</htmldb:BOX_BODY>');
This deals directly with the special page template for PPR pull's it should have unique substring's for clipping out the text you want. To make it easy I create tags with a htmldb: namespace with the name of the specific region, we don't use any xml dom stuff because more than likley the page you pull from will not be properly formed xml.
You can even get cut down more on the html over the wire by using one region for the whole page but I like to do things generic also then you can make more complex region pulls where you are pulling multiple regions across region substitution tags.
The main problem you can have with this is that you want to make sure not to get the <form> tag included in your substring as that will break the submit functionality on the calling page.