0

Wondering if someone can help me with what I thought was a simple Shapesheet issue.

I'd like the fill colour of a shape to change based on one of the shape data values. I thought I could do this easily:

FillForeground: If(Prop.Colour="Blue",XXX,YYY)

But this doesn't work? (Visio 2021)

I've 5 list values for the data and would like a different fill colour for each? Weirdly, I can see that the value does change based on the data selection, but the actual colour seen in on the page doesn't.

Obviously, I'm not much of a coder, just an enthusiastic meddler.

I've stuck at:

=IF(Sheet.3780!Prop.StringSection="Firsts",THEMEGUARD(MSOTINT(THEME("LineColor"),40)),THEMEGUARD(MSOTINT(THEME("AccentColor"),40)))

(The shapes to colour are within a group)

Thanks Steve

1 Answers1

1

Steve !

FillForeground: If(Prop.Colour="Blue",XXX,YYY)

But this doesn't work? (Visio 2021)

For compare strings in ShapeSheet you must use STRSAME function
Use syntax like this:

IF(STRSAME(Prop.color,"blue"),4,3)
Surrogate
  • 1,466
  • 2
  • 11
  • 13
  • 1
    May be this article can helps: [Choose Colors with Shape Data Fields](http://www.visguy.com/2009/10/21/choose-colors-with-shape-data-fields/) – Surrogate Apr 29 '22 at 08:09