Click on a button and Change dynamically the value of a select control

Hey there,
I hope you’re doing fine.

I’d like to dynamically change the value of a select control by clicking on a button.
Any idea of how I can do so ?

Many thanks

1 Like

Hello Adrien,

What do you want to update the control value from and to? You could probably use a “table” with one row and one cell that you reference as if it were a control, then use a button to update that row as you normally would. Does that make sense?

Thanks,
Bobby

Hey Bobby,
Thanks for your answer.
This is actually what I’m doing, but I was wondering if there were not a more fancy solution.
I just want to change the value of a select control without the use of a temporary cell.
Something like [name_of_select_control].setValue(“New Value”)

A little more context :
I have a table with all my contacts and the company they’re in.
I have a table with the companies name.
I wish I could use some select control to let the user filter the contacts by company, but I’d also like that the user could select a company by pushing a button in my company table.
So, when the user pushes the button, the select control take the name of the company, and only the contacts from this company would appear.

Hello Adrien,

Take a look at this, it’s not perfect but it allows a bit more fluidity by combining the “hidden” variable option and the full range of values, of course, it is problematic, because if they change the control themselves, it will no longer dynamically update via button.

https://coda.io/d/_dFxV8UVJTJt

I believe this is the max that can be done with current functionality, so I think it would be a good feature to force update the actual selected option of a control.

Sorry, maybe someone else has some thoughts,
Bobby

2 Likes

Hey,
Thanks for the - nice - try :slight_smile:

Yep, I think a setValue fonction that could be triggered by a button could be a nice feature.

But for now, I’ll stick with the one cell solution which, either if it’s not perfect works pretty well !
Thanks again for the time and efforts you put in finding a solution Bobby.

Cheers.

Hi Community, Team
Any news/follow up about this request? (Oct 2018?)

Is there a way to set the value of a particular control (date, date range, select etc.) programmatically?

The use case is for an “Advanced Search” mask i’m creating for a table.
I created several controls to ease the filtering part, but with some buttons i would like to set certain values of those controls…

Any advice is much appreciated!

Francesco

4 Likes

And now - Jan 2020 - looking for this function myself. Ended up using the single row table solution… messy but it seems to work.

1 Like

And funnily enough - here I am 4 months on researching this again, and I see my own post. I’ve got yet another use case for this where I’ll have to resort to a 1x1 table.

2 Likes

I would also love to have this function available!

I’m posting this as a solution to the original question, but will also add this topic to our notes for feature wants.

2 Likes

Hello, any update on this functionality ?

The workaround does the job but its not elegant…

Thanks

This is in our notes and something we are aware of, we want this for docs we use internally as well. This isn’t a project yet so no ETA at the moment, but that doesn’t mean it won’t be something we look into adding.

Our current focus is largely on performance.

Hi there! This recent update may help: Launched: Set control value action