Since I'm new and struggling with the Dashboard UI for Node Red, I'm asking the question.
How do I pass a Value of a Slider and a Switch into a Function to work with them. msg.payload doesn't work.
I'm sorry, I know that it is probably a pretty easy question. Just not used to programming with JS.
Thanks in advance
Thats my current code of the function just for testing: in the future i want to use the value of a slider to get passed by if the switch is true
if(msg.payload === true)
{
return 20;
}
msg.payloaddoesn't work? All the UI nodes output values inmsg.payload. Edit the question to include the code you have tried and explain what errors you are seeing. - hardillb