Skip to content

How can I change the color of a Color Switch? #290

Answered by marcus-j-davies
normanth asked this question in Q&A
Discussion options

You must be logged in to vote

Hi @normanth

For that, you will use something like the bellow

CC: Color Switch
Method: Set
Params: [{'hexColor':'#374b96'}]

The Params input supports JSOnata. -so you can pass in a msg property for the colour also

Params: [{'hexColor':payload.color}]

The params are an array, of any object (based on the CC/Method being executed)

But, to be honest you should really be using the ValueAPI, as its superior to the CC API

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@marcus-j-davies
Comment options

@normanth
Comment options

Answer selected by normanth
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants