Skip to Main Content

Java Development Tools

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!

How to check if select one choice component only contains 1 option?

Roger MarquisSep 28 2021

Hello all.
On the page I'm currently developing there is a popup which contains a tree table component with multiple columns and select one choice components, and one child disclosure also containing an soc component.
I am seeking a way to check if there is only one select item choice in the soc dropdown, and if so, I want the soc to default to the only available choice.
The soc components are populated dynamically and so may contain a varying number of elements in each dropdown. I have been trying to find a way to count the number of elements in the dropdown but have not found a successful way to count the number of items for both parent and child node lov/soc components.
So basically, I want to check if the soc item list count equals "1". If there is only "1" item option, then default the soc to that value.
Thank you for reading.
My Jdeveloper version is 12.2.1.4

Comments
Post Details
Added on Sep 28 2021
3 comments
278 views