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!

Show region on button click

600733Dec 19 2007 — edited Dec 26 2007
Hi, I want to show/hide a region when user clicks on a button.

I saw the example in "http://apex.oracle.com/pls/otn/f?p=11933:29:3342298547087148"

I created a region with static id = "REGION1"
I then created a button "Test" with button type as "Template Driven" and action as "Redirect to URL without submitting the page".
I selected the button template "BUTTON" and selected the Target as URL
In the URL Target section I have
$x_Show('REGION1');

but when I run this page, and when I click on the button Test, I get a javascript syntax error.

When I checked the call that is being made on clicking the button, I found that the call is as follows:

javascript:'redirect('$x_Show('REGION1');)'

This call indeed has syntax errors (notice the single quotes).

I am not able to solve the issue.

I read the "Advanced user guide" for APEX. The pdf also mentions the same steps to be able to call javascript function from a button. But this is not working.

What is wrong here?

Message was edited by:
Ketan
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jan 23 2008
Added on Dec 19 2007
11 comments
3,317 views