2 Replies Latest reply on Nov 21, 2012 6:29 AM by Myvizhi Selvi

    How to return from Child Page to Immediate Parent Page

    Myvizhi Selvi
      Hi All,

      I have created a custom OAF page and linked the same with 3 standard OAF pages(Lets say Standard-Page1, Standard-Page2, Standard-Page3) in such a way that whenever I click the GO button in any of those standard pages it navigates to my custom page.

      As of now when I click the BACK button in the custom page it navigates back to Standard-page1(Because i have given the page1 Path in the pageContext.ForwardImmediately) only even though if I would have opened my custom page from standard-Page2 or 3.

      I need to understand what should I do to navigate back to the exact standard page from which the custom page has been opened.

      Any help on this would be greatly appreciated.

      Many thanks in advance!

      Kind Regards,
        • 1. Re: How to return from Child Page to Immediate Parent Page
          Sumit Chandra Sharma
          Dear Myvizhi,
          You can create a return link/back button on the custom page which would take you pack to th previous page. Do ensure that the AM is retained when you navigate from standard to custom page. This would help you navigate back to standard page and have the AM retained. Only thing to be careful of is to ensure you have some parameters handled in the Standard Controller so that the rendering layout and query executions are not invoked again.
          I can suggest further if you need details.

          1 person found this helpful
          • 2. Re: How to return from Child Page to Immediate Parent Page
            Myvizhi Selvi
            Hi Sumit,

            Thanks for your kind reply. I tried another way because we will not have that Standard AM in the Custom Page. The other way is like, getting the standard page URL into a variable and passing it as a session value and getting that session value into a variable in the Custom Page. Then passing that variable in the place of URL in the following way:

            In the Standard Page passing URL variable into a session value:

            String s4 = pageContext.getCurrentUrlForRedirect();
            pageContext.putSessionValue("*previousPageUrlForList*", s4);

            In the Custom Page getting session value into a variable and using :

            String valuefromsession =(String)pageContext.getSessionValue("*previousPageUrlForList*");

            true, // retain AM

            Kind Regards,