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!

Apex 5 Database Procedure Error is displayed as Ajax message. Any way to make user friendly ?

RunrigJan 23 2017 — edited Jan 24 2017

I have looked at a number of posts on this and so far I have yet to find a solution. I am very new to Apex, so if this seems obvious, I am sorry.

  • I have a database procedure which I am calling from a dynamic action (button click).
  • The database procedure is raising an exception (which is all good, as expected)
  • APEX 5 catches that exception and displays it as a AJAX error in a popup window along with the full ORA-Blah Blah message. Not very meaningful to the end user.

So I would like to take the error message from the procedure and display it to the user in a meaningful way. I just want to display a message of my choice to the user on the page. I have tried

apex_application.g_print_success_message := '<span style="color:red">my message here</span>';

apex_error.add_error (

    p_message          => 'My Message Here'

    p_display_location => apex_error.c_inline_in_notification );

I have tried in my database plsql code using htp messages. I am guessing is is very basic and I am just missing something.

This post has been answered by Mahmoud_Rabie on Jan 24 2017
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Feb 21 2017
Added on Jan 23 2017
4 comments
1,291 views