Ok, I have created a conveyor belt which I have individual png’s drawn for each belt segment. I have then created a Dynamic property for each belt which I have tied to a PLC tag and used an expression to create a range of numbers to change the belt color accordingly using a style. I then have an individual line (All belts for one system) in a container which I can then copy the container to add to an overview
I have it working great and it looks good for the first line and I need to do 7 more lines now. I stared with line 4 and am now going to create line 1 so I created a new container for line one … copied line 4 into the new container … moved a few lines around and now I am going through the tedious process if changing all the expressions to point to the correct tags. Is there a way to do a global search and replace on a unigue string.
For example I have one belt listed below … this expression is attached to each belt and the only thing to change is T1-01, T1-02, T1-03 etc … I have about 30 belts per line.
If I could search the T1 and replace it with T4 for an entire container it would save me a bunch of time.
The Dynamic Property I created I called ColorTag and tied the following expression to it.
if({[ROC_5911001]T1-03}>134217727,100,
if({[ROC_5911001]T1-03}>67108863,90,
if({[ROC_5911001]T1-03}>4194303,80,
if({[ROC_5911001]T1-03}>1048575,100,
if({[ROC_5911001]T1-03}>524287,40,
if({[ROC_5911001]T1-03}>262143,61,
if({[ROC_5911001]T1-03}>131071,70,
if({[ROC_5911001]T1-03}>2047,60,
if({[ROC_5911001]T1-03}>511,50,
if({[ROC_5911001]T1-03}>63,51,
if({[ROC_5911001]T1-03}>31,100,
if({[ROC_5911001]T1-03}>15,30,
if({[ROC_5911001]T1-03}>7,20,
if({[ROC_5911001]T1-03}>3,40,
if({[ROC_5911001]T1-03}>1,11,
if({[ROC_5911001]T1-03}>0,10,0))))))))))))))))
Any suggestions would be greatly appreciated !
FYI the color Style which corresponds with the above expression looks like this …
"ColorTag","animationIndex","animationDuration","tintColor"
"0","0","1000","color(128,128,128,255)"
"10","0","1000","color(0,217,0,255)"
"11","0","1000","color(128,128,128,255)"
"11","1","1000","color(0,217,0,255)"
"20","0","1000","color(0,0,0,255)"
"30","0","1000","color(255,0,255,255)"
"40","0","1000","color(255,140,0,255)"
"50","0","1000","color(255,255,255,255)"
"51","0","1000","color(128,128,128,255)"
"51","1","1000","color(255,255,255,255)"
"60","0","1000","color(255,255,0,255)"
"61","0","1000","color(128,128,128,255)"
"61","1","1000","color(255,255,0,255)"
"70","0","1000","color(71,255,255,255)"
"80","0","1000","color(0,0,217,255)"
"90","0","1000","color(172,95,0,255)"
"100","0","1000","color(255,0,0,255)"
"101","0","1000","color(128,128,128,255)"
"101","1","1000","color(255,0,0,255)"
Chris