How to update Grasshopper function through human UI

Dear Community!

I have a little problem: I was programming a changeable shape in Grasshopper. Then I made a UI with Human UI. Unfortunately I can not get the grasshopper slider to change accordingly to the Human UI sliders.

I added a Value listener, so the UI changes when I use the slider in grasshopper but not the other way around.

The file is attached. I’m sorry for the mess, as I am a beginner.

changing_line.gh (14.4 KB)

Thank you!

Please review the example files from Human UI on food 4 rhino - correct configuration takes a little getting used to but is explained in the first example file. https://www.food4rhino.com/app/human-ui It is also explained in this tutorial video: https://vimeo.com/153923789

You should not be modifying a slider connected to a create slider component. You should treat that slider as a “default value”, and use the value from the value listener as the input to the logic of your definition.

Bi-directional “syncing” of a slider to the UI is possible but requires a different approach involving Metahopper - take a look at the “Decoupling snippets” on food4rhino for an example of this approach.

1 Like