-
Assign a colorcode to a Color property basing on the compName
Hello, I want to assign a color to Fill effect based on the compName. Let’s say I have 3 colors: Black (#000000), White (#FFFFFF) and Grey (#808080) and I want to apply each color for every third comp.
My comps are named like this – “1. First Comp” “2. Second Comp” “3. Third Comp” and so on…
Currently I wrote an expression like this for the “Color” property of the Fill effect:
var n = thisComp.name.split(".")[0]; if(n%3 == 0) { FFFFFF; } else if(n%3 == 1) { 000000; } else if(n%3 == 2) { 808080; }But this expression is throwing an error. Any help is really appreciated…