Visio 2007 - Will pivot node display the correct name data if purchase full product?

U

u828576

I'm using the Beta eval version and have noticed the node name is Pivot
Node.13 rather than the name that gets displayed on the node.

E.g the Node Category is Hello World but the node name is Pivot Node.13

Will this property display the correct data item if the full product is
purchased or am I on the wrong path to get the node name?
 
J

John Goldsmith

"Pivot Node.13" is the name and ID of the shape. Visio uses ID numbers so
that it can uniquely identify different shapes on a page.

The text in the shape (eg your Hello World) should be visible in the "Shape
Data" window. If you can't see it, make sure that the menu item
"View/Shape Data Window" is checked and if you still can't see it then you
may need to drag down the PivotDiagram window below it.

Let me know if that helps.

Best regards

John


John Goldsmith
www.visualSignals.co.uk
 
U

u828576

Hi John,

Thanks for your reply

Yes shape data window correctly has "Hello World" - is there a way to
reference this value in shape data programatically in code eg.

for each shape on the sheet
If shape.name = "Hello World" then apply a shape to the node
end for

btw is it possible to apply a shape programatically??
 
J

John Goldsmith

Yes, programatic access to Visio is what for me makes it such a powerful
application. If you haven't already you should have alook at the
"ShapeSheet" behind each shape. To view a shape's ShapeSheet (make sure
that the Tools/Options/Advanced/Run in developer mode" is checked) right
click the shape a select "Show ShapeSheet". From here you can view and
change virtually all of the shape's properties (some are only availble from
code). Programatic access is, in simple terms, just a case of reading and
writing to those cells. So your code below would look something like this:

Sub FindMyHelloShape()
Dim pag As Page
Dim shp As Shape
Dim shpNew As Shape

Set pag = Application.ActivePage
For Each shp In pag.Shapes
If shp.CellExistsU("Prop.Resources", 0) = True Then
If shp.Cells("Prop.Resources").ResultStr("") = "Hello World"
Then
'Drop new shape below this one
Set shpNew = pag.Drop(shp.Master, _
shp.Cells("PinX").ResultIU, _
shp.Cells("PinY").ResultIU - 1)
End If
End If
Next shp

End Sub

Pivot Diagrams are slightly more involved but fundamentall work on the same
basis.

So here's a little bedtime reading for you.

The main books are:

"Developing Visio Solutions". Also available online at:

http://msdn2.microsoft.com:80/en-us/library/aa245244(office.10).aspx (see
chapter 18 to get going with Drawing Automation)

"Visualizing Information with Microsoft Office Visio 2007" by David Parker

http://www.visualizinginformation.com (a must if you're serious about Pivot
Diagrams)


Other online resources are:

John Marshalls MVPS site: http://visio.mvps.org/

Chris Roth's blog: http://www.visguy.com/

The Visio Insights blog: http://blogs.msdn.com/visio/default.aspx

plus, of course the SDK (2007 version -
http://www.microsoft.com/downloads/...b8-5ef7-4e6e-a582-c8d6b5ee4e33&displaylang=en)


Hope that helps

Best regards

John


John Goldsmith
www.visualSignals.co.uk
 
D

David Parker

Wow! Someone has bought it! Thanx
(I hope you don't use IE 6 to view the companion web site, though)
 

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