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 21.1 Popup LOV inconsistencies (displayValueFor)

Scott WesleyMay 12 2021

Hi,
I'm still experiencing inconsistencies between Select Lists and Popup LOVS when using the displayValueFor function in Oracle APEX 21.1.
I have a sample page here with a select list and a popup lov based on data from EBA_UT_CHART_PROJECTS
image.pngIf I try show values using a literal string I get different results

console.log(apex.item( "P3_SELECT" ).displayValueFor('3'));
console.log(apex.item( "P3_POPUP" ).displayValueFor('3'));
Email Integration
3

If I manually select some values, then use displayValueFor on $v, I get consistent results

console.log(apex.item( "P3_SELECT" ).displayValueFor($v('P3_SELECT')));
console.log(apex.item( "P3_POPUP" ).displayValueFor($v('P3_POPUP')));
Documentation
Documentation

If I set the values using a PL/SQL dynamic action
image.pngthe placeholders shift up in response, but only the select list displays a selection
image.pngBoth items have values set (and in session state)

console.log($v( "P3_SELECT" ));
console.log($v( "P3_POPUP" ));
4
4

But if I use display value for, then only the select list returns a value.

console.log(apex.item( "P3_SELECT" ).displayValueFor($v('P3_SELECT')));
console.log(apex.item( "P3_POPUP" ).displayValueFor($v('P3_POPUP')));
Documentation

It would be great if these behaviours were the same for Select Lists and Popup LOVs, as the documentation suggests.
The Popup LOV is such a wonderful component for the end user, but the programming behaviour continues to be a frustration.
I thought displayValueFor would be a workaround for the PL/SQL issue as a subsequent action, but alas.

Comments
Post Details
Added on May 12 2021
1 comment
805 views