J
John Beyer
(My apologies if this defect has already been reported and addressed.)
Problem: The cell values displayed in the shapesheet's Protection section
for a shape can get out of sync with the formulas in those cells.
Products: Visio 2003, Visio 2007 Beta2 (I haven't checked earlier versions.)
Scenario:
1. Start up Visio; make sure it's running in developer mode in the
Tools->Options... Advanced tab. You may also want to uncheck the "Open each
ShapeSheet in the same window" option.
2. Open a new diagram (a Basic Diagram is fine) and draw a simple shape on
it (a rectangle is fine). Open the Drawing Explorer window.
3. Use the Format->Define Styles... dialog to create a new style named
TestStyle that is based on "No Style". In the Includes section, uncheck the
Text and Line options, leaving only the Fill attributes option. Click on
Fill... to edit the style's Fill attributes. Change some of the fill settings
to some distinctive fill color and pattern, and click OK.
4. In the Drawing Explorer, select the new TestStyle and open its
shapesheet. In the style's shapesheet, scroll to the Protection section and
manually change all of the Protection cell formulas (except LockDelete,
LockSelect, and LockFormat) to "1".
5. Select the shape on the diagram and open its shapesheet. Open the Style
dialog using Format->Style..., and set the shape's Fill style to TestStyle.
(Leave "Preserve local formatting" unchecked when applying the style.) The
shape's fill will change to the color/pattern you defined for TestStyle. In
the shape's shapesheet, scroll to the Protection section, and note that the
corresponding Lock properties have also been set. (This is, as far as I know,
an undocumented feature; the Protection locks in a style are treated as Fill
attributes.)
6. Select the shape again if necessary and change its Fill style back to
Basic. In the shape's shapesheet, note that the shape's protection locks have
been returned to their original values (i.e., "0") as expected. So far, so
good.
7. Re-apply TestStyle to the shape's fill style to change its fill and
protection locks again. With the shape selected, open the
Format->Protection... dialog. Click on "None" to clear the selections in the
dialog, and click OK. Note in the shape's shapesheet that the corresponding
Lock properties have been set back to zero, and are now colored blue to
indicate local formulas.
8. In the shape's shapesheet, select each Lock cell with a local (blue)
formula and clear the value (hit Backspace twice, then Enter or an arrow
key). Note that these Lock formulas are now set to match those in TestStyle,
and that the shape's behavior is constrained appropriately.
9. Re-apply the Basic style as the shape's Fill style. The shape's fill will
change back to the Basic values. Open the Format->Protection dialog for the
shape; note that the Lock flags have NOT been cleared (!) and that the shape
is still constrained by the locks. However, the shape's shapesheet will show
the shape's Protection cell formulas as 0's (i.e., equal to the values in the
Basic style). Switch to the "Values" view for the shapesheet; note that the
actual values being used do not match the constant formulas from the Basic
style, even though the formulas are being shown as non-local (black). It is
apparent that the Protection lock values are not now being recalculated to
match the style formulas. This is inconsistent with the behavior in Step 5
(above), in which lock values did stay in sync.
10. Click on each Protection cell and clear its formulas again (as in Step
8). Note that the lock value for that cell is now recalculated. (However, if
we re-apply TestStyle, the lock values will fall out of sync again.)
Admittedly, this is a rather convoluted scenario that ordinary users are
unlikely to see. Nevertheless, this should be corrected so Visio geeks like
me don't go crazy trying to use this "hidden" feature.
Has anyone else seen or heard of this behavior?
Problem: The cell values displayed in the shapesheet's Protection section
for a shape can get out of sync with the formulas in those cells.
Products: Visio 2003, Visio 2007 Beta2 (I haven't checked earlier versions.)
Scenario:
1. Start up Visio; make sure it's running in developer mode in the
Tools->Options... Advanced tab. You may also want to uncheck the "Open each
ShapeSheet in the same window" option.
2. Open a new diagram (a Basic Diagram is fine) and draw a simple shape on
it (a rectangle is fine). Open the Drawing Explorer window.
3. Use the Format->Define Styles... dialog to create a new style named
TestStyle that is based on "No Style". In the Includes section, uncheck the
Text and Line options, leaving only the Fill attributes option. Click on
Fill... to edit the style's Fill attributes. Change some of the fill settings
to some distinctive fill color and pattern, and click OK.
4. In the Drawing Explorer, select the new TestStyle and open its
shapesheet. In the style's shapesheet, scroll to the Protection section and
manually change all of the Protection cell formulas (except LockDelete,
LockSelect, and LockFormat) to "1".
5. Select the shape on the diagram and open its shapesheet. Open the Style
dialog using Format->Style..., and set the shape's Fill style to TestStyle.
(Leave "Preserve local formatting" unchecked when applying the style.) The
shape's fill will change to the color/pattern you defined for TestStyle. In
the shape's shapesheet, scroll to the Protection section, and note that the
corresponding Lock properties have also been set. (This is, as far as I know,
an undocumented feature; the Protection locks in a style are treated as Fill
attributes.)
6. Select the shape again if necessary and change its Fill style back to
Basic. In the shape's shapesheet, note that the shape's protection locks have
been returned to their original values (i.e., "0") as expected. So far, so
good.
7. Re-apply TestStyle to the shape's fill style to change its fill and
protection locks again. With the shape selected, open the
Format->Protection... dialog. Click on "None" to clear the selections in the
dialog, and click OK. Note in the shape's shapesheet that the corresponding
Lock properties have been set back to zero, and are now colored blue to
indicate local formulas.
8. In the shape's shapesheet, select each Lock cell with a local (blue)
formula and clear the value (hit Backspace twice, then Enter or an arrow
key). Note that these Lock formulas are now set to match those in TestStyle,
and that the shape's behavior is constrained appropriately.
9. Re-apply the Basic style as the shape's Fill style. The shape's fill will
change back to the Basic values. Open the Format->Protection dialog for the
shape; note that the Lock flags have NOT been cleared (!) and that the shape
is still constrained by the locks. However, the shape's shapesheet will show
the shape's Protection cell formulas as 0's (i.e., equal to the values in the
Basic style). Switch to the "Values" view for the shapesheet; note that the
actual values being used do not match the constant formulas from the Basic
style, even though the formulas are being shown as non-local (black). It is
apparent that the Protection lock values are not now being recalculated to
match the style formulas. This is inconsistent with the behavior in Step 5
(above), in which lock values did stay in sync.
10. Click on each Protection cell and clear its formulas again (as in Step
8). Note that the lock value for that cell is now recalculated. (However, if
we re-apply TestStyle, the lock values will fall out of sync again.)
Admittedly, this is a rather convoluted scenario that ordinary users are
unlikely to see. Nevertheless, this should be corrected so Visio geeks like
me don't go crazy trying to use this "hidden" feature.
Has anyone else seen or heard of this behavior?