How to open DropdownSearch widget using a button?
Application Type

I have a DropdownSearch widget from OutsystemsUI module and I want to open it (show the list) when clicking a button.

I tried calling this javascript code in the Button on click but it doesn't work.

Is it possible to achieve this?


Hi Kenneth,

Yes, it's possible.

  • Add a custom style class (e.g., dropdowSearch--js) to the DropdownSearch widget as highlighted below.

  • On Button click, invoke the open method for the dropdownSearch element using JS as shown below. 

JS Snippet:

setTimeout(function() {

Demo screen: DropdownSearchTask

Note: The DropdownSearch widget in the latest OutSystemsUI references Virtual Select JS library

For more info, refer to the official Virtual Select JS documentation:

Refer to the attached oml file.

I hope this helps you!

Kind regards,

Benjith Sam


Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.