Fix Page References in Visio 2003 Shapesheets

D

Dr. Ho

I seem to have bumped into a bug.

I'm having a problem automating my table of contents in one of my drawing
sets. I have set up the shape sheets and custom properties I need, but can't
access them from another page.
The command I'm putting in the field is "=Pages[Title]!ThePage!Prop.Title"
and all I get when I hit insert is that there is an "Error in the Formula"! I
tried creating a new page (Page-3) and putting an idential Property on it,
then referencing that, and it worked!
Then, to make it all even more interesting, I renamed Page-3 to Title2 and
opened the shapesheet with the reference from my Table of Contents page. The
cell still had "=Pages[Page-3]!ThePage!Prop.Title" in it and the link was
still working, despite the change of page name which wasn't changed in the
formula(?!).
I tried refreshing things by saving, quiting, and reopening the drawing, but
this only made it worse. The one reference I inserted still works and shows
"Page-3" while the custom formula field in the Insert Field window shows
"=Pages[Title2]!..." and yet if I try to write another field from any page
referencing Title2 it doesn't work, but Page-3 still does!!

Anything you can do for me?
Thanks,
Brian Williamson

----------------
This post is a suggestion for Microsoft, and Microsoft responds to the
suggestions with the most votes. To vote for this suggestion, click the "I
Agree" button in the message pane. If you do not see the button, follow this
link to open the suggestion in the Microsoft Web-based Newsreader and then
click "I Agree" in the message pane.

http://www.microsoft.com/office/com...39ac83505ea&dg=microsoft.public.visio.general
 
M

Mark Nelson [MS]

This sounds like an issue with universal names. Pages and many other
objects in Visio have two names - a Local name and a Universal name. The
Local name is the name you see in the user interface. The Universal name is
the one you reference in the Shapesheet and through automation.

Why two names? To allow users to rename objects without breaking the
Shapesheet and automation references. This also facilitates international
scenarios where the Local name is translated into specific languages.

When you rename a page, you are changing the Local name but not the
Universal name. Thus your Shapesheet reference cannot use the new name.
The only way to set Universal names is programmatically with the NameU
property.

--
Mark Nelson
Office Graphics - Visio
Microsoft Corporation

This posting is provided "AS IS" with no warranties, and confers no rights.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top