Displaying SharePoint Document Library Column Values on Visio Services Diagrams

It is often useful to be able to link text or graphics to the values in the SharePoint document library that a Visio diagram is stored in. A SharePoint Document library is just a list with columns and Visio 2013 documents can be linked to the data in SharePoint lists … and it will be automatically refreshable. This means that Approval Status changes, for example, can be displayed as text or icons. This article goes through the methodology of linking data from the SharePoint document library to the Visio document.

First, I created a Visio Cross-Functional Flowchart document that was saved into a Visio Process Library in SharePoint 2013 online. Note that it could be in any document library which has versioning enabled, and it does not need to be this particular diagram type.

image

The initial Approval Status is Draft, and the Title column is hidden in this view of the list.

image

I could then use the Link Data to Shapes function, and select either to link the list or a view of the list, as below:

image

This provided me with an External Data recordset, with far too many columns:

image

I switched off some of the columns with the Column Settings dialog. Note that I later realised that I should have checked the Data Type of the Name column because I did not really want it to be automatically creating a hyperlink.

image

I then linked the row from the External Data window to the border shape of my cross-functional flowchart. It could, of course, have been any other Visio shape, but this seemed suitable for this purpose.

image

This linking causes the columns from the External Data window to become Shape Data rows on the shape.

image

I then thought it would be simple to link the Title column from the library to replace the Title text in the border shape. Therefore I added some text into the Title field on SharePoint.

image

I then modified the view settings to display the Title column in SharePoint. In fact, I had to modify all of the template views.

image

In Visio, I ensured that the option to Overwrite user changes to shape data was ticked.

image

I then wanted to replace the Title text in the border shape, but I realised that the actual text was in a sub-shape of the group, so I checked the ID of the group shape that contains the Shape Data with the DEVELOPER \ Shape Name button.

image

Knowing the ID of the group shape meant that I could use INSERT \ Field with a Custom Formula ( = Sheet.1!Prop._VisDM_Title ) to replace Title with data linked text.

image

So, the text is now going to be automatically refreshed from the SharePoint document library list column value.

image

I then checked the document back into SharePoint.

image

This action then requested that I decide on the version and to enter any optional comments.

image

The Approval Status changed to Pending

image

So, I then had to decide whether to Approve or Reject my own changes.

image

This dialog then enabled me to Approve or Reject the changes to the Visio document:

image

The Approval Status changed again in the SharePoint list:

image

The Shape Info pane in the Visio Web Access web-part in a SharePoint web page automatically updated with the latest values.

image

I did notice that the Visio Web Access control displays the numeric equivalent of the Approval Status:

0 = Approved

1 = Rejected

2 = Pending

3 = Draft

However, this methodology means that I can now reflect the Visio documents version, status, etc., as text and/or graphics within the Visio document itself. This is very useful for version control, and for including on any prints that may also be created.

One Response to “Displaying SharePoint Document Library Column Values on Visio Services Diagrams”

  1. Making unused data-linked SharePoint columns in Visio invisible automatically | bVisual - for people interested in Microsoft Visio Says:

    […] and why I sometimes a SharePoint document library to Visio documents in a previous article ( see https://blog.bvisual.net/2015/02/10/displaying-sharepoint-document-library-column-values-on-visio-ser…). I mentioned that I always switch off the visibility of some columns because they are rarely […]


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

davecra.wordpress.com/

Microsoft Office Development, and more...

PowerShell.Amsterdam

Automate, Accelerate, Accurate

johnvisiomvp

Life with Visio and other Microsoft Toys!

Title (Required)

Windows Server Essentials Tips & Tricks

Nilsandrey's Weblog

Just another WordPress.com weblog

Things that Should be Easy

Every so often (too often in the IT industry) I encounter things that should have been very easy to do but turned out to be far too complicated. My favorite topics include SharePoint, .Net development, and software architecture, especially distributed systems.

Visio Guy

Shapes, Stencils, Drawings Templates, Tutorials, Tips & Developer Info for Microsoft Visio

Hannes's Virtual Earth

Tips & Tricks around Mapping and Cloud Computing

Pluralsight blog

be smart, be clear, be visual ...

%d bloggers like this: