This is the personal blog of David J Parker ( About Me ), Microsoft MVP for Office Apps & Office Servers with a specialisation in Visio, based in the UK, and MD of bVisual ltd (see http://www.bvisual.net ).

It contains tips and tricks and sample code for intermediate to advanced Visio users and developers (and a few occasional ramblings about other stuff too).

If you find this blog useful, then feel free to donate at : Donate via PayPal

I am the author of four books about Visio …


Mastering Data Visualization with Microsoft Visio Professional 2016



Book 3

Microsoft Visio 2013 : Business Process Diagramming and Validation


Book 2

Microsoft Visio 2010 : Business Process Diagramming and Validation


Book 1

Visualizing Information with Microsoft® Office Visio® 2007


73 Responses to “About”

  1. Nick Says:

    Hi David,

    Have you ever created a customised form for entering shape data? For example have Field A then next to it having a checkbox for the validation of the data.

    I find the shape data window very non-user friendly when there is a large amount of shape data and the dialog box that it uses is good but it’s main limitation is that it restricts the number of fields.

    BTW I’m using Visio 2007


    • davidjpp Says:

      Yes, I have done it with VBA, WinForms and WPF (my favourite) in the past. When talking about validation, then you need to have somewhere to store the constraints … lately I have used an XML file, but if you have a database, then it could come from there.

  2. nishant202 Says:

    Hello David ….

    I am Nishant and I am training to become a Business Analyst in Noida , India…
    I have been trying to learn about MS-Visio 2010 in my training …Although there are online trainings available for MS-Visio but I want a classroom training in it as I believe a face to face training will help me master it

    Can you suggest me what can I do ???


    Email : nishant202@gmail.com

  3. Prakash Says:

    Hi David,

    I would be very grateful if you could point me in the right direction, i am trying to show SCOM 2007 R2 Performace Data such as Memory/CPU usage as a Guage on a Visio Chart. I have no idea on how to accomplish this. any step by step documentation would be useful

    thanks in advance

  4. Prakash Says:

    Tried what? 🙂

  5. James Says:

    Hi David,

    The original WBS Modeler i’ve read was released with source code. As you were the original author,is it possible to get a copy of your last release? I realise it would be a well outdated version? The current WBS Modeler does not do some things well (formatting, controls on what levels to output) and I was hoping to learn from the old code and go from there.


  6. Ali Lomneck Says:

    I am using Visio to create flowcharts that I would like to publish as part of my company’s product documentation on the web. I have tried the Save As > Web page function and the flowcharts, which are on larger-than-normal-sized sheets, are zoomed out to the point where shape text is just squiggly lines. The links, etc., work fine, but users will have no idea what the shapes are pointing to.

    Any tips on how to publish large diagrams to the web and still have readable text on them?

    Thanks for your help!

    • davidjpp Says:

      Do you publish in VML (if using MS IE) or XAML ?
      If so, you should be able to zoom in on the items.
      Any other format is going to pixelate and become unreadable.
      Another tip is to use the User.visEquivTitle cell to create a tooltip for the shapes. see

      • dick penny Says:

        I cannot get the user.visequivtitle cell to show a tooltip in 2010 when viewed in SharePoint. Insert tooltip works in visio, hyperlinks work thru to SP.

      • davidjpp Says:

        I assume that you mean with the Visio Web Access control?
        Well, that is using Silverlight to display the Visio documnet, so it doesn’t understand User.visEquivTitle, whih was introduced for html.

      • davidjpp Says:

        I should have added that, with the Visio Web Access control, you can use JavaScript to display whatever you want from the Shape Data values anyway … so it can be far better than just relying on User.visEquivTitle

  7. THE Says:


    I’m a grad student in Jamaica trying to show a historical timeline with dates pre 1899 (my research covers 1800-2009). This rules out using Visio’s timeline based on the dates it will accept. I want to show events for 5-6 thematic areas. Some have no duration, others have durations. I thought about getting the event data displayed in shapes that were spread out based on date.

    I have the information in a excel file. Based on the number of rows of data 209 and the number of thematic areas I need to automate this. I know I need to link shapes to data or use the database wizard to make the two programmes talk. But then there are a couple of other things I would like to do – colour the shapes by theme, have the different themes running at different heights and the MAIN THING, have the shapes arrayed by date. Display width is not an issue, this does not have to fit on letter size paper, but could fit on say a 11 X 36 roll out.

    Can you give me some guidance on how to proceed?


    • davidjpp Says:

      The minimum date of 1/1/1900 is shared across all Office apps, so it is not just a Visio issue. I have some thoughts about how you can achive other dates, and use Link Data to Shapes, so I’ll prepare a post and come back here in the next couple of days.

  8. THE Says:

    Thanks for responding. I look forward to your forthcoming post


  9. THE Says:

    Thanks for responding. I look forward to your forthcoming post

  10. David Says:

    I just purchased your Visio 2007 book…The book is great, however the companion website to download the code is terrible! I have never had to go through so much to download sample code! At least give an option to download all chapters at one time instead of individually.

  11. David Says:

    I am trying to add some fields to the qorg chart master shapes…I have deleted all the shape data from the master shapes…then I add the new fields that I needed. If I open the modified master shapes the shape data fields are correct, but when I add them to a drawing there are 2 new shape data fields…Name and Title? Are these required for an org chart so visio adds them if they are not present?

  12. Cliff Vaught, PMP Says:

    The images for “Linking Visio WBS Modeler Diagrams to Project” don’t seem to work. Is it something on my end or yours?

  13. Dan Says:


    I am working with the WBS Modeler Add-On with Visio Professional 2010 and I’m using a fairly large WBS. However, the add-on does not include the option of aligning the child elements vertically. Is this an option that was left out because it seems like a very useful tool to more easily represent the data. If you have any insight on this issue, please get back to me. Thank you

  14. Kons Says:

    Hi David,

    I wrote an Visio 2010 Add-In which convert some process diagram-files into another process diagram-files. It just iterates through every file and create paralell file which contains “my” process shapes. Everithing looks fine, but discovering the shapes which I drop in swimlanes I realize, that only the shapes from the FIRST source file are members of container in the FIRST target file. Then, for the next files 2,3,…n all shapes are correctly positioned, but they aren’t members of the respective containers. When I change the source file names, then again, only the containermembers for the first created file are really container members(shape.MemberOfContainers). In your last book, I couldn’t find solution for this problem(maybe I’m too lazy to read patiently/carefully). I think that it’s could be something with the file.close() order, bur I’not sure.

    • davidjpp Says:

      I think that you may not have used the shape.AddToContainers method?

      • Kons Says:

        Yes 🙂 that was it. Yet I use shape.AddToContainers after every shape.Drop
        Very strange, for the first processed file I also didn’t use it and the shapes of the first created file are containermembers 🙂
        Thank you!

  15. David Says:

    Hi David,
    I am building an orgchart with about 1500 employees and am spreading it across about 50 pages. I’m using vb.net (visio Interop) and a DB to build the chart using a custom stencil. I can add the shapes to the correct page along with the shape data fields and connect the shapes correctly…my issue is trying to figure out how to arrange the shapes on the page so that all shapes fit and it looks presentable without human intervention.
    In my DB I have fields that are used to configure what page each person should be placed on as well as the org structure, so that part is configurable if I have to many shapes on a page I can move people to a different page very easily.
    Am I on the right track or is there a better approach?
    Thanks for any suggestions you can offer!

  16. Kons Says:

    Again I have a question and I think you are the one who can help me. I want to edit the Microsoft swimlane master shape(cross-functional flowchart) so that when I drag it into the page no Title or Separator are visualized. Only Swimlanes should be visible on the Page. I could uncheck “Show Title Bar” and “Show Separators” later, but that is unsatisfactory for me. I tried to completely delete the ShapeSheet Row User.visMasterStencil: “xfunc_m.vss”, but then usefull functionality get lost.
    Can you suggest me a solution for this problem?

  17. mickrose Says:

    Hello David,

    I need to create several state of the art Communication Network Matrix + diagram.
    I urgently need a visio 2007 or 2010 template (data sheet + diagram) looking like this diagram+ details:

    The data needed are similar to what you get in the Windows Resource Monitor under TCP Connections, see:
    http://i.imgur.com/PNCYF.jpg (ignore the arrows)
    local IP, remote IP, ports…

    I am ready to hire someone or get hints.
    thanks a lot,

  18. Neil Says:


    Im trying to create a data graphic that has an Icon Set in it that can have multiple options to get the same icon, e.g. Y or N/A will give the same icon. What i cant do is work out how to get visio to do this? Cant see how to enter the formula in the Edit Icon Set dialogue box, and when i try something like:


    in the visDGCalloutIconNumber user cell in the master no icon shows, which I’m assuming means visio has made it to the -1 in the IF statement. Cant see what I’m doing wrong as this:

    =IF(STRSAME(User.visDGFieldAD,User.visDGFieldAC,TRUE),0, IF(STRSAME(User.visDGFieldAD,User.visDGFieldAF,TRUE),1,IF(STRSAME(User.visDGFieldAD,User.visDGFieldAE,TRUE),2,-1)))

    works to display 3 different colour icons. Any ideas appreciated!

    • davidjpp Says:

      Are you using the Edit Icon Dialog to enter a custom formula for the Data Field?
      You can use it to return values, which you then use to Equal a Value to display an icon.
      For example, your formula (with superfluous brackets taken out)
      should return 0,1 or -1
      which you can then set to three icons for those values

      • Neil Says:

        I was diving into the shapesheet for the master for the icon on the data graphic as i couldnt see how to get the formula in, was trying to put the formula into the rule for the icon rather than the data field. All working now, appreciate you taking time to provide the answer! Like all these things, obvious when you know how.


  19. Ettien Joean Says:

    Office 2013 Exercise


    I’m on retirement and based in Ivory Coast West Africa. I was trying to use Visio 2013 following your guide using the excel file FinancialMgtDataSet (sample) for Pivotdiagram

    This error occured “The selected file is not a Microsoft Excel File or is currently inacsessible”

    I don’t understand why this error.

    Could you help me to solve it.

    Many thanks in advance

  20. Martin Says:

    Hi David,

    I hope you can assist me with this. I purchased your book on Visio validation from Amazon.com. I have implemented the validation rules for a specific template successfully. I would like to know is there any way I could change the appearance of the shape causing the Issue within the Issues window? I tried something like the following but it was unsuccessful:

    Public Sub EnumerateShapeIssues()

    Dim shp As Visio.Shape
    Dim issue As Visio.ValidationIssue
    Set shp = Application.ActiveWindow.Selection.PrimaryItem

    For Each issue In shp.Document.validation.Issues
    If issue.TargetShape Is shp Then
    shp.CellsU(“LineColor”).Formula = “=RGB(255,0,0)”

    End If
    End Sub


    • davidjpp Says:

      Your code works on simple shapes, ie those which are not groups, and thus have the geometry at the selected shape level.
      I suspect that your shapes are groups, therefore you would need to iterate through all of the sub shapes to change the line colour.
      Of course, this is not always desirable because lines may have been set to other colours for design reasons.
      Then you have the problem of re-setting the colour back to the original. You can do this in code for instances of a master shape by :
      shp.CellsU(“LineColor”).Formula = “=”

      Note that selecting a group shape, then using the Line Color option from the ribbon will automatically iterate through all sub-shapes to change the colour.

      Other strategies could be to :
      1. Change the layer that a shape is on, and set the layer colour to red.
      2. Add a user-defined cell or shape data row to denote that the shape has an issue or not. Then use data graphics to colour by value or add an icon.

      In my book and the accompanying add-in, I use reviewer’s comments for shapes with issues.

      • Martin Says:

        Hi David,

        Thanks for your detailed reply. I figured out a way by amending some of the code snippets suggested in the reviews from your book. I’m basically looping through every shape on the page, and then comparing the shape’s ID with with the target shape’s ID associated to a particular Issue within the Issues Window. It works fine for me. Your book assisted me greatly!


      • Martin Says:

        Hi David,

        I know this should be fairly easy, but I just can’t get it going. I would like to call the validatation.validate method from every time a dynamic connector is either connector or disconnected. I got it working for every shape drop and after every text edit though. Could you please give me a hint on this?


      • davidjpp Says:

        I would recommend that you listen to the page ConnectionsAdded and ConnectionsDeleted events to Queue affected connections for processing after application NoEventsPending fires.

  21. Martin Says:

    Hi David,

    Thanks for the advice I got it working. I would like to ask you one last question. Currently, Visio allows you to select an Issue in Issues window, which then selects the target shape in the page. Is there any way I could do this the other way around. Say, when I select the shape in the page, it will automatically select the associated issue in the issues window.

  22. Andre Heller Says:

    Hi David,

    thanks for your informing blogposts and your contribution to the Visio community.
    We’re facing a big nasty problem in Visio 2013. Microsoft changed a lot under the hood, especially its rendering engine. An inacceptable side effect to these changes is a blurred rendering of any CAD, which worked in Visio 2010 nice and fine. see

    I’ve tried to raise a bug report through official MS support channels, but it looks like this issue got stuck and there won’t be any fix soon. As this issue affects a lot of customers and blocks them from switching from Visio 2010 to Visio 2013, do you have any more close relations to Visio Product Group at Microsoft to raise the issue with a bit higher priority?


    • davidjpp Says:

      I agree that it is unacceptable, and, even better, so do my friends at Microsoft. They are taking this very seriously and would like to have any examples that you are willing to share privately. Just email me a link and I will forward it to them.

      • Andre Heller Says:

        Solved in Service Pack 1 for Visio 2013:

        Rendering of CAD-Files is crisp and sharp, just like in the old versions of Visio.

        btw: Due to the fact, that the CAD-import-implementation is rather old and not very reliable, we’ve been working on our own code to import DWG, DXF (including the latest file versions) and came up with a pretty promising solution. If any one is interested; just contact me.

  23. Joe Says:

    Hi David,

    I am trying to drill down my visio diagram which is a couple of pages long. I was trying to use the hyperlink but cant find the shape names to address in the filed. I hope you could give me some help on it.

    • davidjpp Says:

      The Name of a Shape can be viewed\edited by selecting Developer \ Shape Name , if you have File \ Options \ Advance \ Developer Mode ticked.
      It can also be seen in the header of the Size & Position or Shape Data windows … these can be opened from the View \ Task Panes drop-down.
      You can use the name in the Hyperlink Sub-Address Shape field.

  24. Joe Says:

    Thanks david for the quick help

  25. Martin Says:

    Hi David,

    I need some assistance with understanding how the different objects communicate when a diagram is validated. I have created rules within a macro. As I understand, when the validation method is called, the Document object communicates with the Validation object to trigger validation? How does the validation API retrieve the shapes in the diagram?

    I know somehow the validation API uses the Connectivity API to retrieve a set of connected shapes, but I can’t seem to find a thorough explanation of the different objects involved in the validation process.

    I hope my questions are not to advanced for your blog.


    • davidjpp Says:

      I assume that you have read my book, especially Chapter 4 http://www.visiorules.com ?
      You just have to listen for the Document.RuleSetValidated event, then call your own rules code, as in this example from my book:

      Private Sub Document_RuleSetValidated( _
      ByVal ruleSet As IVValidationRuleSet)
      If ruleSet.NameU = “bVisual” Then
      CheckAllPagesArePortrait ruleSet
      End If
      End Sub

      • Martin Says:

        Hi David,

        My rules work fine in my implementation, but I’m just curious how the process works. I don’t quite get how the the RuleSetValidated Event links in with the Validate method?

        For example, when the user clicks “check diagram” button, does it initiate the RuleSetValidated Event from the document object, which then in turn, calls the validation object to validate the diagram through the Validation method?

        If I call the validate method straight away from, for example, the Shape_added event in a Macro, it works fine as well?

  26. Nick Says:

    Shape question: Master shape with Dynamic Glue.
    1) I edited the Master Shape so that it has one connection point in the center of the shape. (x=width*.5 y=height*.5)
    2) In Shape Layout, I changed the “ShapeFixedCode” to 64. (visSLOConnPtsOnly). This is supposed to get the dynamic lines to connect only to the Connection point and not to the nearest exterior of the shape.
    Q1) What else do I have to change to get the dynamic lines to connect to the connection point? They are still connecting to the exterior of the shape.
    Q2) How do I bring the shape to the front and move the line to the back automatically, so that the shape hides the overlap.
    Note: I can manually move the line to the connection point. It just doesn’t automatically snap to it. I am using the scale feature of Visio, and the line needs to be the full length of the distance.

    • Nick Says:

      I tried ‘ShapePermeableX’ ‘ShapePermeableY’ and ‘ShapePermeablePlace’ all set to TRUE.

      • davidjpp Says:

        If you are trying to get dynamic glue to apparently connect to the center of your shapes, then just change the Page Setup | Page Layout |Style to Center to Center … you don’t need any connection point in the center of your shapes for this option.

  27. Nick Says:

    Hmmm. No, that doesn’t do what I want.

    Visually, it looks the same as what I can do manually. But the dynamic line is connecting to the edge of the shape (it shifts when the object is rotated so the line always points to the center of the line).

    The difference is that the length of the line

    A center to center line being 20 ft.

    The dynamic line, center-center is 14 ft 1.1339 in.

    The difference being the size of the shape on either end. (5ft 10.8661 in).

    If I manually pick up the line and move it to the connection point on the line, then the line is the correct length.

  28. Nick Says:

    If I look at the ShapeSheet for the line, what I am getting is:

    What I want is:


    • Nick Says:

      If I manually add a connector, the connector is snapping correctly to the center connection point on the shape.

      It is not working correctly, when I drag a new master shape onto the drawing. The auto-connector drawn then is connecting to the shape using the shape center-shape center line that ends at the shape edge.

      • davidjpp Says:

        Are you saying that the length of the connector is important to your solution?
        Are you using the Match master by name setting on your masters?
        Do you want to send me a document with your problem explained?

      • Nick Says:


        The length of the connector is important to the solution.

  29. Nick Says:

    I am using your bVisual macro to get the length of the line and keep it updated.

  30. Hank Says:

    My recorded Macro to Automatically Link my shapes to data will not run by hand. It performs fine during the Record.
    But when I run the Macro i get an “Invalid Parameter” error.

    I have tried adjusting the values to the AutomaticLink method.
    This recorded line:
    Application.ActiveWindow.Selection.AutomaticLink 11, ColumnNames1, FieldTypes1, FieldNames1, visAutoLinkReplaceExistingLinks, IDsofLinkedShapes1

    became this:
    Set vsoSelection = Application.ActiveWindow.Selection
    vsoSelection.AutomaticLink Application.ActiveDocument.DataRecordsets.ItemFromID(11).ID, ColumnNames1, FieldTypes1, FieldNames1, 8, IDsofLinkedShapes1

    But still the same Error.

  31. Oriol Rofes Says:

    Hi Dave,
    I am using WBS modeler and it seems I cannot change the size of the shapes. I would like to make the shapes bigger as there is too much space and visually is hard to follow if you want to show and discuss with different team members. Is there anything that can be done?

    Thank you very much,


    • davidjpp Says:

      Yes, there is.
      Go to Design / Re-Layout Page / More Layout Options, then adjust the spacing
      If you want more control then go to the Page Setup / Layout and routing / Spacing dialog.
      Change the space between shapes. You may need to add then delete a shape to see the changes.

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 )

Google photo

You are commenting using your Google 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 )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.


O365 and SharePoint

Simplify Tasks

Want to learn the simple way?

Paul Turley's SQL Server BI Blog

sharing my experiences with the Microsoft data platform, SQL Server BI, Data Modeling, SSAS Design, Power Pivot, Power BI, SSRS Advanced Design, Power BI, Dashboards & Visualization since 2009

John Goldsmith's visLog

be smart, be clear, be visual ...

Mo's blog

Personal views on Dynamics 365 for Operations and Technical Architecture.

Chris Webb's BI Blog

Microsoft Power BI, Analysis Services, MDX, DAX, M, Power Pivot and Power Query


Azure Solutions for Office 365, and more...

Rob Fahrni



Life with Visio and other Microsoft Toys!

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

Smart graphics for visual people

%d bloggers like this: