I have a text box and a select box in my rich DSPF. My requirement is simple. Whenever, the user clicks on the text box, a user click on the select box should be simulated and the dropdown with the list of options must be displayed. i.e, the select box options dropdown must be displayed as if the user clicked on it.
Please let me know if this can be achieved through a onClick event of the text box widget?
This sounds a lot like our Combo Box widget. Can you use that?
If you wanted to write your own... we don't actually use a select box for the combo box, even though it looks like one.. instead, we place an image that looks like a down arrow at the edge of the text box, and when you click it, it opens a div element that's styled to look like the list of options.
The code you provided would work as well... but, this does not quite do what you asked...? (It doesn't really open the dropdown, it just displays more options from the dropdown on the screen. If you look in the "All Widgets" section of the widget toolbox, you might notice we have both a dropdown and a list box -- these are actually the same widget with different settings. one shows multiple lines on the display, the other shows one but allows you to drop it down... that's what your HTML/JS code does, too.)