Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Close Popup and Redirect Parent

Mike Straka-OracleAug 25 2011 — edited Aug 31 2011
Hi,

I have an application with a report page (page 3) showing a list of opportunities. There is a button on the page to add an opportunity. Clicking this button redirects to a form page (page 241) in a popup window using the button action = redirect to url with the url:
javascript:html_PopUp('f?p=&APP_ID.:241:&SESSION.::&DEBUG.:241:P241_BRANCH_BACK_PAGE:&APP_PAGE_ID.','','800','900','yes','yes');
On the popup form, there are two buttons. The Cancel button simply closes the window, again with a redirect to url:
javascript:self.close();
The Create button submits the page for normal DML processing. I have added a final page process on the popup page of type 'close popup window' that is conditional on pressing the Create button. This all works fine, the popup closes, the database is updated and the user is back on the report page 3.

However, what I really need to do is instead of having them back on the report page, I need to redirect them to another page (page 242) where the can add additional details to the row they just created in the popup form.

Is there a simple way to do this? I have searched the forum and the web extensively. Perhaps I'm not using the right search terms, because I haven't come up with a solution. I've tried various javascript approaches to alter the parent window url (e.g., window.opener.href = "<url>", but of course this doesn't work after the page has been submitted.

I suppose it would be possible to have an application item that I could set in the popup page and then have an "On Load: Before Header" branch on the report page that would check the value of this application item and redirect to the detail page (242) if it was set to a particular value. Is there an easier/more direct way?

Thanks!
Mike
This post has been answered by S-Max on Aug 31 2011
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 28 2011
Added on Aug 25 2011
3 comments
3,154 views