Shape properties displays like hiearchical data

Started by meks, March 19, 2010, 06:05:12 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Was this post helpful?

Yes
0 (0%)
No
0 (0%)

Total Members Voted: 0

meks

Guys,

Is it possible by any means to display the properties(Shape Data) in visio much more like a collapsable menu items.

Please refer to the navigation pane(left side of your browser as you open the page) of MSDN microsoft.com on how I want it to look like.

Please guide me in creating the code or whatsoever, thanks so much.

Yacine

You have this functionality already almost in Visio.
If you arrange the drawing explorer and the shape data windows one above the other, you get a hierarchical view + the data of the shapes.

Note that you can write a macro, which would generate an anchored window with a treeview, that you would populate with a all the relevant objects.

Personaly, I liked very much the tools of:
http://www.exontrol.com/

And the anchored windows can be found in the SDK:
http://www.microsoft.com/downloads/details.aspx?FamilyId=373D34B8-5EF7-4E6E-A582-C8D6B5EE4E33&displaylang=en

Good luck
Yacine

meks


Hello Yacine.

Thanks for the info you helped me a lot...

My problem now is how do i set up Visio to automatically launch/display shape data window+drawing explorer window as I share my Visio file and at the same time protecting the whole document from all kinds of editing/copying and closing all the functions I want it only to display.. I know I can protect the shapes in my document and the properties by GUARD command in the shapesheet...But can Visio protect drawing pages like excel can protect its excelsheets???

Thanks a LOT!  :D

Yacine

Hi Meks,
Search for "password" in this forum and you'll see that there's no comfortable protection  as in word or excel.
However there are alot of workarounds. It all depends on what you want to do. There are differences, whether u just want to display data, or allow certain inputs as well.
The more u tell use, the better we canhelp.
Bye
Yacine

meks

Yaccine,

I want to use all the features Visio can offer such as Drawing Explorer, Pan and Zoom window, Shape Data Window, the ctrl+F function (finding shapes), Linking Data to Shapes without risking the drawings I make subject to changes or editing when I share my files with others. Security Issues.

Moreover, I was able to protect my drawing using the shapesheet, also disabled some of the editing commands such as Define Shape Data, but this was not enough, for when I display the drawing explorer window, the Shapesheet function can still be launched on the Drawing Explorer window, unless I restrict the shapes from selection. When I disable the shapes from selection, the Shape Date window doesnt display data anymore, it just sems that I cannot make it all work with protection along.

Can a VBA CODE protect the Visio Drawing from editing???

Thanks so much.  :D

Yacine

Hi Meks,
I wonder if Visio is the right tool for the task.
If you don't want people changing a drawing, then you could use PDFs as well.
If you need the user to enter data, then you coud either show a picture of your drawing and provide input fields.
Another approach could be the use of the Visio Viewer for display and VBA/VB forms for the interface.
The latest is probably the easiest and most reasonable. (By the way also the cheapest - only your personal license)
Yacine

Jumpy

Quote from: meks on March 29, 2010, 05:38:24 AM
Moreover, I was able to protect my drawing using the shapesheet, also disabled some of the editing commands such as Define Shape Data, ...

Could you tell me, how you disabled the define ShapeDate? Would be nice to know.

Yacine

#7
ganz schön bissig der Jumpy.  ;) :D ;D
Yacine

Nikolay

Quote from: Jumpy on March 29, 2010, 07:29:10 PM
Could you tell me, how you disabled the define ShapeDate? Would be nice to know.

I can think of the following ways:

1. You can do that using Windows group policy and admin templates (admin's way). This is AFAIK the official way of disabling commands in Visio.
Please refer to MSDN for more info here.

2. Visio 2010 specific stuff: You can just disable command with corresponding "idMso" in your custom user interface definition.

<customUI ...>
  <commands>
    <command idMso="bla-bla-bla" enabled="false"/>
  </commands>
</customUI>


The list of Visio commands (and group policy ids) can be found here.

3. You can do that using UIObjects or CommandBars, by disabling corresponding controls/menu items by id.
But I'd recommend you  buy a squirrel before speeding down this pathway :D

Regards, Nikolay.

meks

Jumpy,


Place a code GUARD(1) on the label LockCustProp in the Protection section of the shapesheet of your shape and it'll disable the define shape data.

Other protection related options can also be located in that section of the shape's shapesheet, GUARD() command makes the options free from UI alterations, however, define shape data and other protection options can still be enabled again only through shapesheet. Use GUARD() command on the Values of the properties too to prevent deletion and alterations in the values, a little tidbit there.

My problem now is how to lock the Shapesheet itself.  :D

I hope that's essential. :D

Jumpy

Thank you all, I will play with it a bit.

@Yacine: Keine Angst... Ich will nur spielen...  ;D