In Oracle Apex, use apex.item("ITEMNAME").getValue()
or $v("ITEMNAME")
JavaScript methods to get item value. Below are the examples:
Example 1: Get Item Value using apex.item().getValue() JavaScript Method
In the following JavaScript program, it will get the P2_TOTAL
item value (total amount) in a variable n_amount
:
var n_amount; n_amount = apex.item("P2_TOTAL").getValue();
Example 2: Get Item Value using $v() JavaScript Method
The program will do the same task as above but using the $v() JavaScript method:
var n_amount; n_amount = $v("P2_TOTAL");
Related Tutorials:
- How to check if the item is empty/null using JavaScript in Oracle Apex?
- Oracle Apex - Set Item Value Using JavaScript
Mohamed
Hi,
Both methods don't work with global Application items. Is there any methos to use with global application items?