News:

BB code in posts seems to be working again!
I haven't turned on every single tag, so please let me know if there are any that are used/needed but not activated.

Main Menu

The thumbnails as seen when opening Visio

Started by Michelle, October 06, 2011, 07:51:51 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Michelle

This may seem an odd question, and I certainly wasn't sure where I should post the question... so please let me know if I need to redirect.  My problem is the thumnails a user sees when they open Visio.  When a user first opens Visio, they see the "Getting Started" screen with their recent templates as thumbnails.  If the template they want is not in the recent list, they can click on a template category at the left where we have all our company specific templates.  Some of our templates have a thumbnail of the first page in the template.  Some of the templates have a generic icon that looks kind of like the Visio icon on the desktop.  I can't seem to find any rhyme or reason to why some are a thumbanail of page 1 and why some are just a plain icon.  Can I control this?

Ideally I'd like to have a thumbnail that approximated what a drawing made with that temlate would look like.  I thought I had really come upon an idea when I found this web posting:  http://visualsignals.typepad.co.uk/vislog/2007/11/hiding-pages.html
I simply created a new first page with a basic drawing on it to create the thumbnail, then I hid the page.  Buuuut, when I hid the page, the thumbnail is once again either representing the "next" page in line or it is just a generic icon.  If I unhide the first sheet, the thumbanil appears as I want.  But I can't have that "new" first page visible to users, as it would most certainly confuse them.

I hope this is making sense!  In short, is there any way to control the look of the template thumbnails?

TIA!
Michelle

Jumpy

#1
Can't answer you initial question, but I remember there was once a thread to this topic already here, although I couldn't find it in my brief search (and I don't remember if there was a solution).

But I can offer a workarround to help your trick with making the first page a dummy page: Create a new first page with a basic drawing on it to create the thumbnail, but don't hide it. So the thumbnail looks like you want it.
Then use a little bit VBA: In VBA-Editor, in the "ThisDocument" modul choose the Document_Opened event and place code there to hide the first page. Best to give the page a special name and use that name to access the page.
Also use the Document_Created event and place the same code there.

Whenever your document is opened or a new one is created from the template the first (dummy) page will hide.

paulgogojuice

Create a template with a first page that looks like you want it to.  Open the Document ShapeSheet and set the PreviewQuality = 1 and the LockPreview = True.  Save and close the template.  Re-Open the template, and delete the dummy first page and resave the template.  This should keep the look that you want. 

Michelle

Paul:  That is on the right track.  Your method took the template I was working with from the generic icon to being a thumbnail of the first page...(because I deleted the dummy first page).  I want the dummy page to be the thumbnail, I wonder if your method would work if I left it there but turned off visibility? 

Jumpy: Thank you... I am still working on your suggestion, and trying not to pull my hair out.  I have absolutely no knowledge of working in VBA, so I am going nuts trying to find stuff on google t help me figure it out.  I tried this:


Private Sub Document_DocumentOpened(ByVal doc As IVDocument)
 
  ThisDocument.Pages("thumbnail").Hidden = True

End Sub


and thought I migth be on to something.  But it didn't work...  I'm still trying, but any more detailed help for this newbie is much appreciated!   :D

Michelle

paulgogojuice

Michelle, if you modify the 2 properties on the document shapesheet that I mentioned, it will no longer matter what your dummy first page is.  Our company does this for all of the templates that we release.

By setting the LockPreview to true once you have the dummy page in there, you can then reopen the template and delete or add any pages you'd like.  It will not affect the preview used.

Good luck.

Jumpy

I would recommend Pauls solution, too, now that I know it.


Nevertheless. You could try to hide the first page with:

ActiveDocument.Pages(1).PageSheet.CellsSRC(visSectionObject, visRowPage, visPageUIVisibility).FormulaU = 1

Michelle

I think I found my problem... but I'm not sure how to fix it.  I can go into LockPreview and set it to True and save the template, but when I re-open the template the setting has reset itself to false!  I tried to "guard" it but it still re-sets itself. 

It seems to work only within the same session of Visio.  I can save the template, close it and re-open and the LockPreview will still be True.  But if I close Visio and re-open (which I *have* to do at some point, especially if I am to put the template on the server for all my users...) it re-sets itself to False and my thumbnails are either my first page(which is just text and not what I want to depict) or a generic icon(definitely not what I want).

Is there a setting in visio causing this re-set upon opening? 

TIA!
Michelle

Jumpy

Are you talking about opening the template again, or do you mean opening (or maybe better said: creating) a new drawing based on that template?

Michelle

Both, actually.  It is happening locally on my computer.  If I close Visio then go right back and click on that template to open it, the value has changed to False.  If I just exit the tem-plate but keep visio open then re-open the template, the value remains True. 

But in the end I guess I need it to work in a new drawing created from the Template, because that's how the end user will be working. 

Just a curiosity, too.  I noticed when I exit Visio then go back into my Template a User-defined Cell section keeps appearing even if I delete it!  The name of it is User.mvsNoAutoConnect, Value is "1".  I am working with templates created by another employee years ago, so tracking this stuff down is sometimes a pain.  How can I figure out what the purpose behind this user-defined section is?  Do I look thru the other shape sheet pages in the file and hope I find it referenced?  Ugh.

btw, I tried the suggestion you gave for hiding the first page, and couldn't get it to work.  I entered it exactly as you had it, then I also tried changing the (1) after Pages with ("thumbnail") which is the name of my dummy page.  I'm sure trying to walk me thru the VBS solution is just going to be too tough, I am truly lost when it comes to that!  I need to see if there are any online courses or even local tech college courses to teach me some basics there...

Thanks for all the help!
Michelle

paulgogojuice

Michelle,
To reopen and edit the template, you need to right click it and select Open.  Double-clicking a template just opens a new drawing BASED on the template.  When you change properties in there, they will only be saved in the new drawing.

Not sure if this is the trouble that you're having, but just wanted to let you know what may be causing problems.

Jim

Michelle

Jim,
Yes, I beleive this may have been my problem.  Thank you.  I can get the file to save my settings now, but when I open Visio from my desktop the "Getting Started" screen that shows the templates does not show the preview dummy page.  The ones that were orginally a generic icon remain the icon, and the ones that were the original first page (just text & instructions for the user) remain that way.  In fact, the ones that show the original first page don't appear to be shown with the higher preview quality... they are very blurry as if I never changed that cell.  (But if I check, the cell *is* changed to Preview quality "1")

Sorry for all the confusion.  I appreciate all your help!
Michelle

Michelle

I'm not sure what I was doing wrong on Tuesday...  I seem to be on the right track today!

Thanks again!

;D
Michelle

Paul Herber

As I've been working on this recently I thought I'd write a short step-by-step article on how create these template previews. I hope somebody finds it useful.
http://www.sandrila.co.uk/articles/visio-articles/adding-template-preview/
Electronic and Electrical engineering, business and software stencils for Visio -

https://www.paulherber.co.uk/

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: 356 (show)
Files included: 34 - 1306KB. (show)
Memory used: 1210KB.
Tokens: post-login.
Cache hits: 13: 0.00179s for 26,726 bytes (show)
Cache misses: 2: (show)
Queries used: 15.

[Show Queries]