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!

how to redirect the page to home after alert message in APEX

LnTInfotechApr 23 2015 — edited Apr 23 2015

Hi All,

I have 4 tab and home page APEX report in that home page I have organization to select as parameter for all the page which is mandatory column so without select the organization in home page I can move to other 4 page but some time users directly pressing the tab for this I have create the ORG_ALERT in each 4 page which this we are able to see the pop-up message when we directly hitting on tab but after select the OK to alert message the page is run for long time and it show all the organization data which I don't want so how can I modify the alert so that after pop-up message it will go to home page.

Declare Output VARCHAR2 (20);

begin 

Output := 1;

Output := NVL( :AI_ORGANIZATION_ID , 0);

IF Output  = '0'  THEN

   APEX_UTIL.SET_SESSION_STATE('AI_ORGANIZATION_CODE','');

   HTP.p ('<script type="text/javascript">');

   HTP.p ('alert("No Organization selected.\n Please select an Organization");' );

   HTP.p ('</script>');  

END IF; 

END;

Regards,

Sushant

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 21 2015
Added on Apr 23 2015
4 comments
665 views