APEX shortcut variables

APEX shortcut variables are best in dynamic use in Javascript code. We can fetch data from database or can use any hard coded text.

Under the shared components we have pretty awesome feature of APEX shortcut. 

We have several source type available to populate the shortcut variables. * PL/SQl Function body
* HTML Text
* HTML Text with Escaped Special Chars
* Images
* Text with JavaScript Escaped Special Chars
* Message
* Message with JavaScript Escaped Single Quotes

PL/SQL function can be followed by:

CREATE OR REPLACE FUNCTION get_date
   RETURN DATE
AS
BEGIN
   RETURN SYSDATE;
END get_date;

Two types of common shortcuts can be like below.

1). HTML

2). PL/SQL

Scope declaration

var plsql_msg = '"PLSQL_MSG"';
var html_msg = '"HTML_MSG"';

These variables can be used in JavaScript for multiple purposes.

alert(html_msg);
alert(plsql_msg); 

Related Posts

Leave a Reply

Your email address will not be published. Required fields are marked *