Configuring SharePoint library to store Visio documents

This post explains how one can set up a standard SharePoint document library to store Visio drawings, with option to create new drawings from a custom template (i.e. to allow your custom templates under “New” button in SharePoint). I’ve spent some time figuring this out for myself.. 🙂 Can be useful when:

1) You have a SharePoint (or Office 365 with SharePoint site, doesn’t really matter). Note that you don’t necessarily need Visio Process Repository (and thus SharePoint Enterprise). You can use normal document library as well (it will also work, just not all functionality will be available).

2) You want to provide some Visio template to your users (or for yourself) so it is possible for them to create new diagrams using that template directly from the site. For example, if you work in some organization, and want your users to use a specific template to draw diagrams.

In this post, I have added a Visio “Template X” as an example (containing “Stencil X”). Note that template and stencil should be stored in the same folder in SharePoint so that Visio can find the stencil when it creates new diagram out of the template.

Here is a step-by-step video:

To get things running the following steps are to be done:

1. Create a template and a stencil.
2. Upload template and stencil to some document library on the site (e.g. SiteAssets)
3. Add new document content type on the site for our template
4. Allow this content type for the document library where you want to store you Visio drawings.

1. Creating a Visio template and stencils.

I think this part is pretty much covered in Visio documentation. Note that you can just use existing Visio template/stencil, in this article I create new ones for demo purposes basically, to show how to make it all from scratch.

2. Uploading to SharePoint site.

Uploading should not be a problem, you just select a target library and save stencil and template to that library. I opted to use “SiteAssets” as it exists by default and contains files related to the site. Note that in SharePoint library settings you have an option to “edit template” – this was designed to work with Word/Excel and may not work as expected for Visio, if you have a custom stencil. So if you have both custom template and stencil, I would recommend to put them next to each other in one library.

image

3. Adding new content type

3.1 Go to Site Settings => Site Content Types => Create
3.2. Enter data form the new content type:
– Name => “Template X”,
– Parent content type => “Document content type / Document”,
– Group => Anything, you can create a new group e.g. “Visio Templates”

image

4. Enabling this content type in the document library:

4.1 Go to Library => Library Settings
4.2 Ensure that “Content type management” is enabled under “Advanced” (option should be checked).
4.3 Click Content types => Add from existing site content types
4.4 Select “Template X” created at the previous step, click “Add”, “OK”. You should get this content type listed now under “Content types”.
4.5 Click the “Template X” now (we will assign template for it now).
4.6 Click “Advanced settings”, and the in the field “Document template” enter the path to the template in the “SiteAssets” document library, like “/SiteAssets/TemplateX.vst”, Click OK.
4.7 Now new option should appear under “New” menu, listing our new template.

That’s it. Now the template should be under “New” menu, and everybody who has access to the library should be able to create new diagram using that template (and stencil).

New Visio book by David J Parker

Davd J. Parker’s new Visio 2013 book was recently released by PACKT Publishing:

Microsoft Visio 2013  Business Process Diagramming and Validation

I personally participated in the review process of this book (as a technical reviewer), and I would like to recommend the book for all Visio users and developers, who model processes with Visio, or develop their own solutions using Microsoft Visio. The book includes a lot of useful information on Visio diagram validation (check out the Rules Tool), Visio solution publishing (in particular, e.g. SharePoint 365 integration), Visio add-in development using .NET and WPF technologies, and many other interesting topics!

If you are a Microsoft Visio 2013 Professional Edition user or developer who wants to get to grips with both the basic features of Visio 2013 and the new Validation Rules in this edition, then this book is for you. A working knowledge of Microsoft Visio, and optionally .NET for the add-in code, is required, though previous knowledge of business process diagramming is not necessary. More experienced Visio users will gain valuable knowledge for building add-ins and creating and publishing rules. If you want to achieve results from Visio 2013 beyond the ordinary out-of-the-box features, then this book is ideal for you. Although this book covers the Professional Edition, much of the book is still useful if you are a Visio 2013 Standard Edition user.

Table of contents

Chapter 1. Overview of Process Management in Microsoft Visio 2013
Chapter 2. Understanding the Microsoft Visio Object Model
Chapter 3. Understanding the ShapeSheet™
Chapter 4. Understanding the Validation API
Chapter 5. Developing a Validation API Interface
Chapter 6. Reviewing Validation Rules and Issues
Chapter 7. Creating Validation Rules
Chapter 8. Publishing Validation Rules and Diagrams
Chapter 9. A Worked Example for Data Flow Model Diagrams – Part 1
Chapter 10. A Worked Example for Data Flow Model Diagrams – Part 2
Chapter 11. A Worked Example for Data Flow Model Diagrams – Part 3
Chapter 12. Integrating Validated Diagrams with SharePoint 2013 and Office365
Index

ShapeSheet Watch – now with multiselect

Here is the updated version (1.0.6). See basic info in the previous post, where the tool was introduced.

FileDescriptionSizeDate
ShapeSheetWatch_2013_11_x64.msi ShapeSheetWatch (x64)3.0 MiB01.12.2013
ShapeSheetWatch_2013_11_x86.msi ShapeSheetWatch X862.1 MiB01.12.2013

Added:

Now supports multi-select.

You can select several shapes, and change a ShapeSheet cell for all of them at once, so you don’t need to edit it for each shape individuality.

12-1-2013 2-31-35 AM

Highlight of changed values.

The values which were changed since last updated are now highlighted. This allows easy visualization of changed values, thus allowing you to understand what effect has a change of one cell to others, or what cells differ between different shapes.

12-1-2013 2-19-22 AM

Filters

Full text search.

You can search for text in a ShapeSheet cell, or for a cell itself, this will allow you to get to the cell/value you are looking for much faster:

12-1-2013 2-22-58 AM

Show only local values

Allows you to filter only values which were defined in shape, and not in the template. These values are normally shown BLUE in the built-in ShapeSheet, and most probably these need to be edited more often.

12-1-2013 2-25-15 AM

Show only highlighted cells

Well, it does exactly that – shows only changed cells. The button is next to the first one =)

Fix shape (PIN)

Allows to turn OFF “following” the shape on selection. if shape sheet is not “Pinned” (default) , then the window shows the data of the selection. If you click now the “Pin” button then window will be bound to the current selection, and will not follow the subsequent changes of selection. By fixing selection of a shape, you can monitor it’s changes when you change different shapes.

New extension: Copy/Move with Base Point

Many drawing products feature so-called “base point” operations. In particular, AutoCad has “Copy with base point”, “Move with base point”.
This operation may be quite useful for precise positioning of the content being copied/moved. To achieve this, at the first step a “base point” is selected, and on the second step a new position for this “base point” is selected. Check out this video to see how it works:

Go to the Extension’s page

VisioWixSetup 1.2 – now with full functionality of Solution Publishing

A milestone of the VisioWixSetup project I’ve been working on – now it can be used to publish anything Visio Solution Publishing Tool could publish, and Visio could understand =)

The changes in this version:

– Added support for publishing ADDONS (EXE/VSL) and help files.
– Fixed an issue with x64 install
– Simplified “starter” wxs file.
– Created project page (with detailed information about all supported attributes)
– Added tests to verify correctess of generated installer.

The new project page

Visio Wix Installer Project Template

The WiX project template for Visio allows you to create an installer for installing Microsoft Visio content (stencils, templates, VSL and EXE add-ons, help files).

This project brings the functionality of Visio Solution Publishing tool from Visio SDK into WiX, so now you can author setup which includes registration (publishing) of Visio-related stuff completely in WiX.

Check it out in Visual Studio gallery:

 11-05-2013 4-19-38

To add Visio publishing to your files to the installer, you can just use one of <visio:Publish > wix extension elements (nest under <File> element). The wizard creates a “starter” sample wix file to build your installer, with two sample Visio files – a template and a stencil.

Continue reading

Improved Visio WiX Setup (version 1.1) – Compiler Extension

I have improved the WiX project template by creating a real WiX compiler extension.
That is, now you can register Visio files with WiX like this (minimalistic example includes just one extra line to publish file):

          <Component>
            <File Name="Stencil_1_M.vss">
              <visio:Publish MenuPath="Group\Stencil 1"  />
            </File>
          </Component>

The updated version is available in Visual Studio Galery:
http://visualstudiogallery.msdn.microsoft.com/68d12e2d-eb42-4847-808a-7d80863bb90d

Continue reading

Visio WiX Setup project in Visual Studio Galery

The Visio Wix setup project was improved a bit. To simplify things, I’ve published it as a project template for Visual Studio in Visual Studio Galery. This is the first time I publish anything in Visual Studio Galery, so that was a bit interesting how to make the wheels rolling:

11-05-2013 4-19-38

In fact, this turned out to be rather easy actually. A good introduction how to publish stuff to Visual Studio Galery can be found on codeproject. That article gives a good  overview, how it all fits together. Anyways, the main result is that now it is possible to create an WiX-based installer project for Visio just like any other project in Visual Studio, please check out the video in the post.

Note that you must have WiX installed to be able to use this project template =)

Continue reading