News:

Happy New Year!

Main Menu

Visio as visualisation tool

Started by lindir, May 20, 2014, 12:43:38 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

lindir

Hello guys!

I create a visio file to follow the production on a machine in my factory. I finish the VBA development and now I have to share the file.
My problem is that I don't what that anybody touch the file apart from me (the other user just eneed to see the content and click on one button to run a macro from time to time)

I don't want them to :
- delete or modify shape
- move shape

I could protect each shape with the protection shapesheet  but it will take me hours to do so moreover my code drop some shape on the activesheet so I will have to drop them and write the code to go in the shaepsheet cells and protect the code....

I there a another way to do so, like in excel for instance:
    ActiveSheet.Protect DrawingObjects:=True, Contents:=True, Scenarios:=True
    ActiveSheet.UnProtect


Of course the previous code doesn't work in Visio on ly in Excel :('

Thanks!

Visio Guy

Hi Lindir,

You could put all of the shapes on layers, then lock those layers. Users would really have to go out of the way to get at the shapes. When a layer is locked, you can't click on its shapes.

Another way is to lock all shapes from selection. Then you have to show the Document Explorer (on the Developer tab), right-click the drawing node and choose Protect Document... In the pop-up, click Shapes. That will lock down all of your shapes from being selected/deleted. But your code can still get at the shapes and manipulate them.
For articles, tips and free content, see the Visio Guy Website at http://www.visguy.com
Get my Visio Book! Using Microsoft Visio 2010

lindir

#2
Thank you Chris:)

I didn't thought about the layer it was quite obvious...

lindir

The layer method didn"t work because the code can'"t manipulate the shape but your second method work perfect..

I have another question, I add to my drawing some Info Bulle ("Tooltip, InfoTipe, Hint" don't know the right translation in English but that the fonction which i savailable in the Insert Tab next to the Text Zone) to some indicator that show Production delay.
With these second method these ToolTip are no longer availabler, any suggestion?

By the way do I have your authorization to re-use this drawing in my project?
I took them from one of your wonderfull article with the glass effect, i was looking for a digital clock and it does a proper job!

Browser ID: smf (possibly_robot)
Templates: 4: index (default), Display (default), GenericControls (default), GenericControls (default).
Sub templates: 6: init, html_above, body_above, main, body_below, html_below.
Language files: 4: index+Modifications.english (default), Post.english (default), Editor.english (default), Drafts.english (default).
Style sheets: 4: index.css, attachments.css, jquery.sceditor.css, responsive.css.
Hooks called: 198 (show)
Files included: 34 - 1306KB. (show)
Memory used: 1056KB.
Tokens: post-login.
Cache hits: 13: 0.00174s for 26,557 bytes (show)
Cache misses: 2: (show)
Queries used: 16.

[Show Queries]