How to get Dropdown value in Knime using JS Part Two

As stated on previous topic,
I would like to know a way of:
1.- select a variable name from a column table
2.- use it as a flow variable
3.- downstream it through the workflow

regards

Hello @hsrb,

guess you are talking about this topic:

To be honest don’t really understand what are you up to. Can you explain it a bit more?

Br,
Ivan

1 Like

Hello Ivan
Thanks for your prompt answer.
I will try to explain a bit more.

I got a single column table with at least 200 rows.
Each row is intended to set a value for the same flow variable wich I want to use downstream.
I want a way to ask the user select wich value (row) that selects and use as a flow variable . Using a dropdown menu.
run the entire workflow with that selected value.

thanks in advance

Hector

Sounds like you need the Value Selection Configuration node here. Point the node at the column that you’re interested in, and it will create a flow variable populated with the value that the user selects, that you can then use downstream. You will need to wrap the node in a component to give the user an interaction point.

If you want to provide this same functionality on the KNIME webportal, you can use the Value Selection Widget instead.

Here’s an example workflow to demonstrate the concept:

2 Likes

Thanky you very much Scott,
Now the node configuration returns the following response:
image

Hello @hsrb,

this is due to domain (error message could/should be improved). See here:

And I agree with @ScottF, seems Value Selection node is the one you need.

Br,
Ivan

Thank you very much guys…!
worked nice for me.
one minor drawback, when I wrap the node into a component, y lost the flow variable configuration for the next node.

regards

Hector

Hello @hsrb,

flow variables that are created inside the component have a local scope and are only available inside the component. Flow variables that are not created within the component are only available outside the component. See this piece of documentation on how to allow the flow variable to exit or enter the component:
https://docs.knime.com/2021-06/analytics_platform_components_guide/index.html#flow-variable-scope

(And keep this guide close by if working with Components :wink: )

Br,
Ivan

2 Likes

Excellent Ivan.
once again, thank you very much for your reply.
Scott thanks to you too.

Worked flauwless for me.

Cheers.

Hector Rondon Blanco

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.