Auto Colour Rectangle/Conditional Formatting

Started by impruv, September 16, 2010, 03:08:05 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

impruv

I'm new to Visio though quite proficient in other Office products. What I'm trying to do seems simple enough but I can't seem to replicate it within Visio.
I basically want to have a rectangle shape and depending on what text I type into that shape, the colour of the rectangle changes. Is this possible with the tools available or would I need to do some VBA?

Jumpy

You can make changes to shape in the ShapeSheet. There you can implement formulas, so that the shape alters it's color, depending on sth. you do or sth. write in a ShapeData-Field. But (as far as I'm aware, and up to Visio 2007 (don't know for 2010)) there are no formulas to make the shape aware to the shape text. So you can either enter your text in a ShapeData Field (that can be displayed on the TextChanged event.

The first solution has the charm, that you could define a fixed list of Values that can be selected as your text and therefore you will know every possibility that can happen and you can display a color for that case.
If you use the ShapeText a user can write what ever he wants in it and to what color would you change the shape if he writes sth, in it, that you didn't expect.

If you go for idea 1, search Chris articles on www.visguy.com for one about changing colors depending on shape data.

Jumpy

impruv

Hey, I managed to do option one with the drop down fixed list when you right click and go to shape data.
There's 3 options being Basic, Competitive, Strategic. I was wondering if there was an easier way to change this value instead of right clicking on the shape, then selecting shape data, then clicking ok.

Is there a window like Shape Sheet that could be kept open at the bottom and thus everytime I click a shape that shapedata will be available to change at the bottom?

Thanks.

Jumpy

There is the very comfortable ShapeDate Window. Go to View->ShapeData Window (in 2007). In 2010 go to the ribbon tab Data, there you can check the ShapeData Window checkbox.

impruv

Quote from: Jumpy on September 18, 2010, 06:24:03 PM
There is the very comfortable ShapeDate Window. Go to View->ShapeData Window (in 2007). In 2010 go to the ribbon tab Data, there you can check the ShapeData Window checkbox.

Ahh thank you very much jumpy. This forum is very informative and awesome :)