This content has been marked as final. Show 10 replies
I think I'm interpreting this correctly, but you probably need to provide info about how your radio button works.
I think what you've done is put a condition on the regions, which mean one of them never renders, so you can't show/hide a region that was never rendered on the page.
Instead, have no condition on the region, but define the dynamic action on your radio button so that it hides one of the regions on page load.
Pending further info, that's all I've got
Thanks for taking a shot at this. The conditions are not actually on the regions, they are on the interactive report and on the tabular report. I have a main page item (radio button) called ReportSelector that is defined: STATIC2:Report;1,Tabular;2
Then in each of the reports, there is a condition based on the ReportSelector that determines if the report is hidden or shown.
Only reason I mentioned region was to say that all three of the above are in the same region ... in case that made a difference. Main problem is that parts of the interactive report fail to function if the page loads with it as default.
Edited by: DenverScott on Apr 30, 2013 9:16 AM
Okay, I have an example that breaks ... I just hi-jacked the demo.
[Should be on the "Customers" tab to start] On any row, click the single link view icon ("page") in the first column. This basically clears out the display ... it should show the details of the selected record. At this point, if you click "Products" on the top tabs and then come back to "Customers" and click the row page again ... it works as expected.
If you log off and then back on, you can re-create problem over and over.
If I had defaulted to the "tabular" report instead of the interactive report, it doesn't break.
(Haven't figured out how to make a guest account yet that doesn't require a p/w)
DenverScott wrote:I don't see an APEX bug here.
Yeah, at this point I'm pretty sure it's a bug with APEX and I'll look to report it. Once I was able to re-create it on the demo site I was pretty sure it wasn't just a mistake I was making.
I think that when Scott W said "without looking under the hood" he meant your app, not APEX. :)
The conditions are not actually on the regions, they are on the interactive report and on the tabular reportThis is the source of the problem. You may need to populate the Page Items to Submit field in the IR with P2_REPORT_SELECTOR
Or your solution requires individual regions for the IR and the tabular form. Hard to tell without looking.
If you share the workspace name and make Test_User a developer account we could log in to take a look.
It looks like you have some page items defaulted to some values that are being used in the interactive report sql where clause, and that page items values hasn't been set into the APEX session state. to reference any apex item using a bind variable syntax OR V function the items value needs to be in the APEX session state.
I have change "Test_User" to a developer, workspace is DenverScott.
Thank you both for the explanation.
One last question of curiousity, why is this not an issue if there is no Tabular report on the display and only an interactive report?
If I delete the radio button, tabular report and remove the conditional from the IR ... everything works without the need for a submit prior to opening the Single Row View link.
Ok, I looked into it. This is a common problem, but you've reached a peculiar example of it because it seems you don't need the value of P2_REPORT_SELECTOR in your SQL for the IR.
BUT, you do because you have it on your Condition.
So, there are two simple ways to fix this. As I mentioned before.
1. You need to populate the "Page Items to Submit" field in the IR with P2_REPORT_SELECTOR
I've done this.
What this does is it makes the value of P2_REPORT_SELECTOR available in persistent session state so that the AJAX call can see that the condition is met and the report should be displayed/rendered.
2. The other option is with a computation on P2_REPORT_SELECTOR that sets it to 1 when P2_REPORT_SELECTOR is null. I left this computation, but set it to Never right now. It's the same net effect because computations save values in persistent session state.
Without the value of P2_REPORT_SELECTOR on persistent session state, the value is only in Memory during render. This is why the page renders correctly. BUT in order for the report to switch to single page view it must know the value of P2_REPORT_SELECTOR and that value was NOT in permanent session state, therefore not available to the AJAX call that refreshes the report.
Same thing when VC did the submit, it saves the value of P2_REPORT_SELECTOR in persistent session state. Same thing that switching the radio button does.
I hope this help you out.