If you want a textbox with suggestions you should take a look at the Auto Complete widget https://appstore.home.mendix.com/link/app/2695/ . We use it and it works really nice, might help you with your requirement.
What you are looking to do could be achieved in a couple of ways within the Mendix client side api: https://apidocs.mendix.com/7/client/
within the API you can use mx.data https://apidocs.mendix.com/7/client/mx.data.html
in order to GET an object from the database for example, or you could use action in order to call a microflow.
hope this helps.