Windows 7 is here, and it makes it easier to find and work with your favorite applications. This post details the work we did in Visio 2010 to take advantage of new Windows 7 features, to make working with Visio documents even easier.
The new Windows 7 taskbar presents a unified interface for launching and switching between applications and documents within them. With Windows 7 and Visio 2010, it is now easier to work with multiple Visio documents at the same time.
We received lots of feedback on the Technical Preview asking for the ability to preview open Visio documents as multiple taskbar items. We listened, and now in the Visio 2010 Beta you can see previews of each Visio document directly from the taskbar, similar to Word and PowerPoint:
By clicking on a thumbnail, you can switch directly to a specific Visio document. If you hover over a thumbnail, Windows shows you a full-size preview of what that window looks like, through a feature called Aero Peek. With Visio 2010 and Windows 7, working with multiple documents at the same time is simple.
For more on the Windows 7 task bar, see this blog post on the Engineering Windows 7 Blog.
Another common request we receive is to enable Visio documents to be edited on separate monitors, similar to Word and PowerPoint. While Visio still displays multiple documents in the same application window, there is a workaround to enable dual display support: launch two instances of Visio.
You can do this in Windows 7 by launching Visio, and then right clicking the Visio icon and clicking on the “Microsoft Visio 2010” item. This will launch a second instance of Visio.
Now that you have two instances running, move one instance of Visio to your second monitor. You can then open two separate files in two separate windows. Even though you’re running two instances of Visio, they are both represented by the same icon in the Windows 7 taskbar, so it’s easy to switch between documents.
If you have a touch-enabled device, Windows 7 allows you to interact with your PC with your fingers. This feature, called Windows Touch, brings a set of gestures to the operating system that can be used in the OS and several applications.
We’ve integrated support for several Windows Touch gestures in Visio 2010:
The above scenarios work directly on the drawing surface, and in full screen mode! Check out the video below to see multi touch in action! (Note: there is no audio).
As seen in the video, we have also integrated the same touch support in the Visio Viewer and in Outlook 2010 preview mode. If you receive a Visio diagram as an attachment, you can use these touch gestures to navigate the diagram directly in Outlook 2010. Click here for more information about Windows Touch
As usual, feel free to drop us a comment on the blog or use the Send a Smile feature in the Visio 2010 Beta to let us know what you think.
Visio Services allows you to view Visio diagrams in SharePoint, and the Visio Web Access web part allows you to embed those diagrams on a web part page. This post examines how you can turn those diagrams into interactive mashups without having to write any code.
This post will show you a few examples of mashups with Visio Services and web part connections, and then it will explain how you can create your own mashups. We’ll finish off by detailing all the web part connection options available and some ideas for you to explore.
In our first example, we use web part connections to visually filter a Visio diagram using a SharePoint list. Visio Services allows you to display dynamic data connected diagrams. If your diagrams are using SharePoint lists as a data source, you can use the list view web part to filter the Visio diagram. As you apply filters to the list, the shapes in the Visio diagram corresponding to the rows in your list view are highlighted.
Below is a screenshot of a network diagram embedded on a web part page. The data is coming from a SharePoint list, and the list view web part is placed next to the Visio Web Access web part, showing some of the data in that list:
When you apply filters to the list, Visio Web Access highlights the shapes that correspond to the rows remaining in the list. So if you want to highlight all the servers that are from a specific manufacturer, or are running a specific operating system, it’s easy to do so. Here’s a screenshot of what happens when you choose to filter and only show servers from one manufacturer:
Notice that there are fewer rows in the list view web part, and that some of the shapes in the Visio Web Access web part are now highlighted with a red border.
You can easily apply multiple filters and clear them to focus your attention on a specific set of shapes. Using this method of visually filtering a diagram, you can look for trends in your data connected diagrams by highlighting a subset of your shapes.
You can also connect two Visio Web Access web parts on the same page to create a master detail view. When you click on a shape in the “master” web part, the “detail” web part displays related information. This is especially useful if you have a complicated process diagram that has several sub-processes, or anytime you want to show detail without losing high-level context.
The image below shows a web part page with two Visio Web Access web parts. The top web part is showing the high level process, and the bottom web part is showing more detail.
Notice in the above image that “Phase 1” is selected. When you click on a different phase in the top web part, the bottom web part updates to show you more information. This is what clicking on Phase 3 results in:
To show you how to setup a web part connection with Visio Web Access, let’s take a detailed look at a third scenario. In addition to being able to highlight shapes based on filters, you can also highlight shapes by setting up a list that contains the names of the shapes you want to highlight. This gives you more flexibility without needing to use the API. The picture below illustrates this. The list on the right contains 3 rows. Each row contains a column with a list of shapes. When you select a row, the corresponding shapes are highlighted.
Notice in the above picture that the first row in the list is selected, and the corresponding shapes are highlighted. Also notice that the second column in the list contains a comma-delimited list of shape names, e.g. “Process,Process.34,Process.70,Process.134”. You can easily hide this column from the view, but it is included here to illustrate the example.
When you change the selected row, different shapes are highlighted:
The following set of instructions show you how to setup the example described above with your own diagram:
You can also setup this connection using SharePoint Designer (SPD). The experience is very similar to the one described above. In the example above, we showed you how to map a field from the consumer web part to the provider web part. Some web part connection actions allow you to specify multiple fields or parameters. To map multiple fields, you should use SPD.
The examples above illustrated a few things you can do with web part connections and Visio Web Access. The list below details the five different connection options supported by Visio Web Access. Some connection actions allow you to specify multiple fields or parameters.
This connection action was used in the Master/Detail example above.
This connection action allows you to send shape data to another web part. When a shape is selected in the Web diagram, data from that shape is sent as a row. By default, the following shape data items are always sent:
To specify additional shape data items to send, open the Web Part tool pane. Type the labels of the shape data items as a comma-delimited list in the box labeled Expose the following shape data items to web part connections.
This connection action was also used in the Master/Detail example above.
This connection action allows you to load a web drawing or switch the displayed page. It takes two parameters:
Visio Web Access will load the web diagram at the specified URL, and switch to the page name specified. If no URL is specified, and only a page name, then it will switch to that page on the diagram that is currently open. If no page name is specified, then the default page will be loaded at the specified URL.
This connection action was used in the highlighting shapes example above.
This connection allows you to highlight shapes in a diagram. It takes two parameters:
When the connected web part sends a shape name or a list of names, Visio Web Access highlights those shapes with the specified highlight color. If no color is specified, a default color is used.
This connection action was used in the “filtering a diagram” example above.
This connection action allows you to “filter” a Visio diagram that is connected to a SharePoint list. The connected web part must contain a SharePoint list that is being used as a data source in the diagram. When the SharePoint list is filtered, the diagram highlights the shapes that correspond to visible results in the filtered SharePoint list. The diagram must be connected to the SharePoint list that the connected Web Part is displaying. For more info on how to create a data connected diagram, see this video.
This connection action allows you to change the view and zoom of the diagram displayed in the Visio Web Access web part. It takes two parameters:
When the connected web part sends a shape name, the Visio Web Access web part centers the view on the specified shape with the zoom level. If no zoom level is sent, then the current zoom percentage is used. You might use this if you have a large diagram and you want to create pre-defined views. For example, if you have a large floor plan, you might setup pre-defined views for different areas of the building.
We’ve shown three examples here of how you can use Visio diagrams and web part connections to create mashups. Here are some other ideas you might try creating yourself:
Web part connections allows end-users, pro-users, and developers to create quick mashups that would otherwise require writing code. We’re interested in hearing what you think of this functionality, please use the Send a Smile feedback tool or leave a comment below.
In our last post, we talked about Visio Services--a new feature of SharePoint 2010 that extends the reach of Visio diagrams considerably. Visio Services lets you:
In this post, we explain how to create a Visio Web Drawing (*.VDW) file using Visio Professional 2010 or Visio Premium 2010. The Visio Web Drawing (*.VDW) is a new Visio file type that allows diagrams to be rendered in full fidelity in the browser using Visio Services on SharePoint 2010.
When you save a file in Visio 2010, you will see the option in the Save As dialog to save your diagram as a Web Drawing.
You can also easily create a Visio Web Drawing using the Save to SharePoint billboard on the Share tab of the Backstage View. This billboard allows you to quickly select a SharePoint location and the Web Drawing file type for saving your diagram.
Clicking on Save to SharePoint at the bottom of the billboard opens the Save As dialog so you can confirm or refine your selection.
To use the default publishing options, press Save. You now have a diagram ready for viewing in the browser!
By default, Visio automatically opens a browser so you can see your diagram as others will see it in the browser. You can turn off this behavior from the Save As dialog.
You can also click on Options at the bottom of the Save As dialog to launch the Publish Settings dialog. Using this dialog, you can select the pages that display and, for data connected diagrams, the data sources that refresh in the browser.
Visio Services allows you to refresh data-driven diagrams in the browser to present the most up-to-date view of the underlying data. The data sources selected in the Publish Settings dialog will be the data sources that refresh. Visio Services supports refreshing the following data sources:
In addition to giving you the option to customize your publish options, the Publish Settings dialog also indicates publishing issues. For example, in the image above, the data source titled “Sales data” has a warning icon beside it. This sales data is stored in a local Excel Workbook: this data source is not supported by Visio Services because it is stored on a local machine. If you want the data from an Excel Workbook to refresh with Visio Services, you should save the workbook to a SharePoint site, link your diagram to the workbook on SharePoint and then save your diagram to the SharePoint site.
On save, Microsoft Visio 2010 generates a Web Drawing file which is in fact a package containing:
Once your Visio Web Drawing file is saved to SharePoint, you can continue to work with it in Visio. Visio Professional 2010 and Visio Premium 2010 both fully support Visio Web Drawing files. This means that you can edit Visio Web Drawing files using the complete set of features provided by Visio.
As you try out Visio Services, please let us know what you think, either by commenting on the blog or via Send a Smile.
In Visio 2010, we completely revamped the Visio user interface and adopted the Office Fluent UI or the “Ribbon”. With the Office Fluent UI, Visio’s extensive capabilities are organized into logical, easy to find groups that help you accomplish tasks efficiently. The breakdown of each of the core tabs in the Visio 2010 Ribbon was explained in a previous post.
Although the Office Fluent UI was designed to help make the Office applications easier to work with, we realize that there is a learning curve for the new Office Fluent UI.
Did you know that there are tools available to help you learn the new Visio 2010 Ribbon?
Looking for a list of the 2007 menu and toolbar commands and their new 2010 locations? You’re in luck! Each Office application has an Excel workbook that lists the old menu commands and their new locations in the Office Fluent UI. You can find these workbooks here.
Would you prefer an interactive program that shows you the new location of a command? Interactive guides for each Office application can be found here. Just click the Visio 2007 command or button that you want to find and the guide will show you its location in Visio 2010. These guides are available as online tools or can be installed on your own computer for use any time (even when you’re not connected to the Internet).
We are enjoying the new look and feel of Visio 2010, and hope you feel the same way! If you have questions or comments about the Visio 2010 Ribbon, please comment on our blog and let us know.
The Visio team is pleased to announce that the online version of the Visio 2010 SDK documentation is now available here. This documentation, which also shipped with the Visio SDK download, is intended to help developers working with the Visio APIs, ShapeSheet and XML. It contains the following Visio developer references.
For Visio Services developers, documentation is available online as well as offline via the Microsoft SharePoint 2010 SDK. This documentation is divided into Visio Services in SharePoint Server overview articles and Visio Services Class Library technical information, and covers the following topics.
As always, we enjoy hearing your feedback about Visio, the Visio SDK and our documentation. Please feel free to post any questions or suggestions to our blog.
In a previous blog post, we explained how Visio 2010 ships with a unique single image architecture. This post explains how to deploy the three different editions of Visio 2010, and how to change the edition of Visio 2010 after you have already deployed it. In particular, the following scenarios are covered:
This post also contains links to more information on Visio 2010 deployment and customizations.
With volume licensing, Visio 2010 can be installed as Visio Standard, Visio Professional, or Visio Premium based on a product key. By default, Visio 2010 uses a Visio Premium 2010 KMS client key, which enables all the features that are available for Visio Premium 2010. If you are licensed to use Visio Standard 2010 or Visio Professional 2010, you must install the appropriate KMS client key. Different features or applications are available, depending on the kind of key that is installed. This makes it easier for you to upgrade or downgrade without having to deploy a different product edition.
For more on this single image architecture, see this blog post: Volume Activation for Visio 2010 Explained.
For more information on Office 2010 deployment in general, see the following resources:
If you’re planning on deploying Visio 2010 to your organization, and want to deploy Visio Standard or Visio Professional, you will need to change the key that Visio 2010 will be deployed with. There are two ways to do this before deployment:
Below are step by step instructions on how to use these two methods. Note that you should only use one of these methods, not both.
Note: this method can be used to install with a key for any edition of Visio, but we’ve chosen Visio Standard for the example.
1. Open up a command prompt and navigate to the directory where the Visio 2010 installation folder is 2. Open the Office Customization Tool (OCT) by calling setup.exe with the /admin switch: 3. Select “Create a new setup customization file for the following product” and choose Visio 2010. This should already be selected by default 4. In the OCT, select “Licensing and user interface” from the menu on the left 5. Select “Enter another product key” 6. Enter the Visio Standard 2010 KMS client key: 7. Click FileàSave and save the MSP somewhere. Choose a name you’ll remember like “VisioStandardKMSKey” 8. Copy this MSP file to the “updates” folder in the Visio 2010 installation folder.
1. Open up a command prompt and navigate to the directory where the Visio 2010 installation folder is
2. Open the Office Customization Tool (OCT) by calling setup.exe with the /admin switch:
3. Select “Create a new setup customization file for the following product” and choose Visio 2010. This should already be selected by default
4. In the OCT, select “Licensing and user interface” from the menu on the left
5. Select “Enter another product key”
6. Enter the Visio Standard 2010 KMS client key:
7. Click FileàSave and save the MSP somewhere. Choose a name you’ll remember like “VisioStandardKMSKey”
8. Copy this MSP file to the “updates” folder in the Visio 2010 installation folder.
Now when you deploy this installation of Visio 2010, it will use the custom MSP file that includes the Visio Standard 2010 KMS client key. This will install Visio 2010 Standard. You can also replace the key in step #6 with a Visio Professional KMS client key or a Multi Activation Key (MAK) for either of the three Visio 2010 editions.
Note: this method can be used to install with a key for any edition of Visio, but we’ve chosen Visio Professional for the example.
1. Navigate to the Visio 2010 installation folder 2. Open the “Visio.WW” folder 3. Open the “config.xml” file with a text editor like Notepad 4. Add the following line to use the Visio Professional 2010 KMS client key: <PIDKEY value="7MCW8-VRQVK-G677T-PDJCM-Q8TCP" /> 5. Save the file
1. Navigate to the Visio 2010 installation folder
2. Open the “Visio.WW” folder
3. Open the “config.xml” file with a text editor like Notepad
4. Add the following line to use the Visio Professional 2010 KMS client key:
<PIDKEY value="7MCW8-VRQVK-G677T-PDJCM-Q8TCP" />
5. Save the file
Now when you deploy this installation of Visio 2010, it will use the Visio Professional 2010 KMS client key specified in config.xml. This will install Visio Professional 2010.
You can also replace the key in step #4 with a Visio Standard KMS client key or a Multi Activation Key (MAK) for either of the three Visio 2010 editions
If you’re planning on deploying multiple editions of Visio, we suggest that you keep three copies of the Visio installation media, and use one of the methods above to customize an installation for each edition you plan on deploying.
The following are the KMS client keys for Visio 2010. These can be used to install Visio 2010, but you will still need a KMS host key with your KMS server to activate Visio installations.
Visio Premium 2010
Visio Professional 2010
Visio Standard 2010
For more on KMS activation, please see the Deploy Volume Activation of Office 2010 article.
If you’ve already deployed Visio 2010 and would like to change the edition that is deployed, you can do so through several ways, none of which require a reinstallation:
1. Use the “Change Product Key” feature on the machine where Visio is installed This can be invoked from Visio 2010’s Backstage View It can also be invoked from Add/Remove Programs à Change 2. Use the Volume Activation Management Tool 2.0 (VAMT) VAMT is a tool administrators can use to manage activations of Office 2010 on managed systems. VAMT can be used to push down a new product key. For more information on how to use VAMT, see the following resources: Download VAMT from here Full TechNet reference on VAMT and how to use it: Managing Activation Using the Volume Activation Management Tool (VAMT) A set of videos on how to use VAMT Deploy Volume Activation of Office 2010 – this article has more information on the methods described in this blog post, as well as how to use VAMT to change keys 3. Use a script that calls ospp.vbs on the machines you would like to change The Office Deployment Support Team blog has a great article and an example script on how to use ospp.vbs with Visio 2010
1. Use the “Change Product Key” feature on the machine where Visio is installed
2. Use the Volume Activation Management Tool 2.0 (VAMT)
3. Use a script that calls ospp.vbs on the machines you would like to change
Note: With any of the methods above, Visio may need to be rebooted up to two times before the user interface and Backstage View update to reflect the new key and edition.
Depending on your User Account Control settings (UAC), in Add/Remove Programs, Visio may still be shown as the previous edition installed.
As always, let us know if you have any feedback on Visio 2010, Visio Services, or suggestions for blog posts you would like to see.
Visio has published the XML Schema Definition (XSD) files for the Microsoft Visio 2010 XML Drawing (.vdx) format. This schema is also known as DatadiagramML. The .XSD files allow developers to better understand the structure of Visio XML documents and design solutions that work with the .VDX file format.
The DatadiagramML Schema for Visio 2010 consists of three .XSD files:
More information about the schema is available in the Visio 2010 XML Schema Reference on MSDN.
Do you work directly with Visio XML files? We’d love to hear about your scenarios in the comments.
Our new Visio blog is filled with tons of articles that can help you make the most of everything Visio has to offer. In it, we have posts on new features, tips and tricks, and ways to make your diagram look both professional and beautiful.
To give you an idea, here's a sampling of our recent articles:
Our blog has lots of helpful information, from revisiting features in earlier versions to highlighting offerings in the new Visio. Check it out for yourself today!
In a previous blog post, we told you about the new Connectivity APIs in Visio 2010 that make it easier for developers to create and to move across a connected diagram. We’ve shown you how to use some of the new APIs to create new connected shapes (see here); now we’ll examine techniques for traversing connected diagrams. One of the most useful APIs for analyzing a connected diagram is the Shape.ConnectedShapes method, which allows you to get a reference to the shapes connected to a shape.
Let’s take a look at a specific scenario to demonstrate how this method can be used to walk through a connected diagram. Imagine that you have a simple project plan, created using the Basic Flowchart template:
In the shape data, each task in the flowchart includes a start date and an end date by which the task must be completed (shown in the chart below).
“Assess needs for project”
“Is project well-defined?”
“Build a prototype”
Ideally, no task in this project should start before the previous task has been completed. You could select each shape and compare the start and end dates in the Shape Data window, but the process would be very manual and tiresome. You could even use Data Graphics to display the start and end dates next to each shape, but it would still require visually inspecting each pair of connected shapes in the drawing.
With the ConnectedShapes method, however, you can write code that walks through each connected shape in your drawing and examine the shapes connected to it. The method returns an array of the shape IDs of all the shapes connected to a shape, filtered by the type of relationship between the shapes (e.g. is the connector “going out” to the other shape or “coming in” from the other shape?). You can also narrow down the returned IDs further by specifying a shape category as an additional filter.
Here’s some simple VBA that will iterate through each connected shape in a diagram and change the fill color of a connected shape if there is unwanted overlap between its start date and the task “before” it.
Dim vsoPage As Visio.Page Dim shapeList Sub TraverseFlowchart() Dim vsoShape1 As Visio.Shape Dim shapeIDArray() As Integer Dim searching As Boolean Set vsoPage = Application.ActivePage Set vsoShape1 = vsoPage.Shapes("Start/End") Set shapeList = CreateObject(“Scripting.Dictionary”) shapeList.Add vsoShape1.Name, 1 GetConnectedShapes vsoShape1 End Sub Sub GetConnectedShapes(shape As Visio.shape) Dim outgoingShape As Visio.shape Dim shapeIDArray As Variant Dim shapeIDArrayNext As Variant Dim outgoingNodes As Integer Dim node As Integer Dim prevTaskEnd As Date Dim nextTaskStart As Date Dim beenChecked As Boolean prevTaskEnd = shape.Cells("Prop.EndDate").result(visDate) shapeIDArray = shape.ConnectedShapes(visConnectedShapesOutgoingNodes, "") If (UBound(shapeIDArray) >= 0) Then outgoingNodes = UBound(shapeIDArray) For node = 0 To outgoingNodes Set outgoingShape = vsoPage.Shapes(shapeIDArray(node)) nextTaskStart = outgoingShape.Cells("Prop.StartDate").result(visDate) Debug.Print shape.Name & " end: " & prevTaskEnd & "; " & _ outgoingShape.Name & " start: " & nextTaskStart If (nextTaskStart < prevTaskEnd) Then outgoingShape.Cells("FillForegnd").Formula = "RGB(255, 0, 0)" End If shapeIDArrayNext = outgoingShape.ConnectedShapes(visConnectedShapesOutgoingNodes, "") beenChecked = shapeList.Exists(outgoingShape.Name) If ((UBound(shapeIDArrayNext) >= 0) And Not beenChecked) Then shapeList.Add outgoingShape.Name, 1 GetConnectedShapes outgoingShape End If Next node End If End Sub
If we run this code on the project plan shown above, we get a result as shown below. Notice that the two shapes that have start dates that are earlier than the previous tasks’ end dates have a red fill applied to them.
In the code sample, the GetConnectedShapes subroutine uses the ConnectedShapes method on the shape passed in as an argument to get an array of the shape IDs (integers) of the shapes that it connects to. (That is, the shape contains the beginning connection of a connector that points to the shapes referenced by the IDs in the array.) Then the subroutine iterates through each shape referenced by the IDs in the array. Next, the value of the “Prop.StartDate” cell of each attached shape is compared to the “Prop.EndDate” cell of the first shape. If the values overlap, the value of “FillForegnd” cell is changed to red.
This code sample also uses the ConnectedShapes method to traverse the connected diagram in a manner similar to “walking” a tree data structure, starting from a specific shape (the first Start/End shape). After it analyzes a shape and one of its attached shapes, the GetConnectedShapes subroutine checks whether the attached shape has any shapes that it connects out to (making another call to ConnectedShapes). If so, the subroutine makes a recursive call to itself (and thereby halting the execution of the original call), passing in the attached shape as an argument. In practice, it is likely that you will need to use this programming technique in conjunction with the ConnectedShapes method in order to work all the way through each shape in a large connected diagram.
(Also notice that the code sample keeps track of each shape whose outgoing nodes have been checked by adding the shape to a dictionary object before the GetConnectedShapes subroutine is called. This will prevent the code from becoming stuck in an infinite loop if the diagram includes a circular reference.)
Even though we’ve used a project plan scenario as the example in this code sample, there are many other practical applications for this technique. In a related but larger sense, you could incorporate this technique within a custom validation checker to determine whether a connected diagram has been constructed correctly. Also similar to the code sample above, you could use this technique to extract and store data from each shape in a connected diagram. (Extending the project plan example, you could get the duration from each task in the workflow and then create a total of all the resource hours needed for the project.)
In the next blog post, we’ll look at another way that you can use this technique and the Page.SplitConnector method to add new shapes to a connected diagram.
A new series of training videos have been posted on Office.com to introduce Visio users to Business Process Modeling Notation (BPMN). The videos are packaged as a course named BPMN Diagramming Basics.
The course provides both an introduction to the BPMN notation and a tutorial on creating BPMN diagrams with Visio 2010 Premium. Along the way you can see some of the other new features of Visio 2010 including Swimlanes, AutoConnect, Subprocesses, and Diagram Validation. The complete course takes less than 30 minutes to view.
Please remember that the BPMN, Subprocess, and Diagram Validation features are part of the Premium Edition of Visio 2010.
Be sure to let us know what you think!
As mentioned in the last post, Visio 2010 has reached the Release to Manufacturing milestone. The product team has spent the last several months incorporating your feedback from the Beta and refining the product. A large community of customers, partners, and MVPs has contributed to this effort. More than 500,000 people have downloaded the Visio 2010 Beta release, and the feedback has been very positive. People have commented on the blog, sent e-mail, submitted Send-A-Smile reports, logged crash reports, and contacted Product Support to provide feedback on the product.
This post describes some of the more visible changes you will find between Beta and RTM. Overall very little is different in the user interface for RTM. The bulk of the work has been targeted at improving reliability (fixing bugs), performance, and security.
Quite a few people commented on the reduced set of drawing tools on the Home tab as compared with the Drawing Tools toolbar in previous releases. Users of the Beta did not know or did not want to go to the Developer tab for the complete set of tools. You can find all six tools on the Home tab for RTM.
At the bottom of the Fill and Shadow dropdown menus in the Home tab are commands to open a formatting dialog for more properties. A similar command is missing for the Line dropdown menu in the Beta. This command has been added for RTM for better consistency across the formatting features.
There are a number of small changes in the Backstage view to make saving files to SharePoint more understandable. First the name of the tab for publishing and sharing files has changed from “Share” to “Save & Send”. Then in the Save to SharePoint place, the option for selecting whether to publish as a Drawing (*.vsd) or Web Drawing (*.vdw) has changed from “Save Drawing As” to “File Types”. Finally the command button has changed from “Save to SharePoint” to “Save As”. The intent is to use familiar terms to describe the actions for saving a document. Also “Save As” makes it clearer that the command will present the Save As dialog to confirm all the settings before saving.
If you apply formatting to a shape (e.g., fill color or pattern) and then copy it to a different page in a themed document, the formatting will be preserved as long as the theme on the destination page is the same as on the source page.
RibbonX is the extensibility framework for the Office Fluent UI. RibbonX provides customization of the Ribbon, the Backstage view, and context menus. Visio 2010 Beta did not support context menu customization, but support has been added for RTM for most of Visio’s context menus. More information on RibbonX extensibility in Office 2010 is available in this blog post.
These are the more visible changes for Visio 2010 RTM from the Beta. There are many more improvements behind the scenes to make Visio 2010 a fast, secure, and reliable release. Thank you for all the Beta feedback. We hope you will try out the final version of Visio 2010 as it becomes available in the coming weeks. Please continue to let us know what you think or want to hear more about.
Recently Mark Nelson from the Visio team sat down with Harry Miller (off-screen) to discuss some of the improvements in Visio 2010 related to process diagrams. The video includes explanations of our Process Management investments as well as demos for Cross-functional Flowchart, BPMN diagram and Validation features.
The conversation is the latest in a video series titled “Visio: Drawing on Experience” posted on Microsoft TechNet. Other videos featuring some of our Visio MVPs can be found here: http://edge.technet.com/Tags/Visio/
In previous posts we introduced you to Containers and some of their special capabilities. We also introduced Lists through their use in Cross-functional Flowchart, Data Graphic Legends and Wireframe shapes. Finally we introduced Callouts as annotations on Visio diagrams. Containers, Lists and Callouts can be used in a wide variety of diagram types. This article explains how shape designers can go beyond the built-in shapes and create their own custom content.
Collectively Containers, Lists and Callouts are referred to as Structured Diagram elements. They establish relationships with other shapes and those relationships define special behaviors. For example, shapes placed into a list are automatically arranged adjacent to one another; a callout shape moves whenever its target shape is moved. Structured Diagram elements are shapes themselves, and thus the special behaviors are defined through their ShapeSheet cells and values.
To designate any shape as a Container, List or Callout you only need to add one User-defined cell called User.msvStructureType. For the value enter “Container”, “List” or “Callout” as desired. This setting tells Visio that the shape is a Structured Diagram element and adds many of the Structured Diagrams behaviors to the shape. In the image below, a rectangle shape is transformed into a container shape by adding the User.msvStructureType cell and setting it to “Container”. However, there are additional settings available to customize the appearance and behavior of your shape, described in the rest of the article.
Any shape with User.msvStructureType = “Container” is treated by Visio as a Container. The following ShapeSheet cells define additional container properties, several of which can be configured in the Container Tools contextual tab in the Ribbon.
If you are creating a container shape from scratch, you will notice that by default the container does not have any Container Style or Heading Style available in the Container Tools tab. Styles are a way to offer different looks for your container through some combination of geometry and formatting changes. The container shape can define multiple visual styles using the User.msvSDContainerStyle, User.msvSDContainerStyleCount, User.msvSDHeadingStyle and User.msvSDHeadingStyleCount cells (in short, the “Style” cells and the “Count” cells). Use the Count cells to tell Visio how many styles your shape supports for the overall container or for the heading. Then determine what ShapeSheet cells should be set for each style. Put formulas in each of these cells that depend on the value of the Style cells. Visio will check the style count and populate the ribbon galleries with each style defined by the container shape. When the user chooses a new style from the gallery, Visio puts that style index back into the Style cells to update the look of the container.
The container shapes in Visio 2010 vary in complexity. The containers in the Insert Container gallery have many visual styles and lots of formulas to change the appearance of the shapes. There are some simpler examples in the Wireframe shapes, which define just a few styles each.
Visio 2010 introduces the concept of Shape Categories to refine the membership behaviors of containers. This is the mechanism used by features such as Cross-functional Flowchart and Data Graphic Legends to ensure that only the right kinds of shapes participate in the list and container behaviors. A container shape can restrict membership by defining a required or excluded shape category. For this to work, a prospective member shape must have a User-defined cell User.msvShapeCategories in its ShapeSheet. The prospective shape lists one or more category names in a semi-colon delimited string. To only allow a specific category of member shape, a container can set that name in its User.msvSDContainerRequiredCategories cell. To allow most shapes as members but specifically exclude a category, a container can set that name in its User.msvSDContainerExcludedCategories cell. (Prospective shapes with no categories defined will not be allowed in a container with required categories, and they will always be allowed in a container with excluded categories.)
The heading of a container is simply the container shape’s text for basic containers. However, it is possible to achieve more sophisticated visual styles if the heading becomes its own shape. For this construction the container becomes a group and the heading is added as a sub-shape of the group. The primary benefit is that Visio can account for the heading sub-shape in sizing and layout operations to avoid putting member shapes on top of the heading. To designate a sub-shape as a heading for the container, add the cell User.msvStructureType to the sub-shape and give it the value “Heading”. Also you should properly set the User.msvSDContainerHeadingEdge cell in the sub-shape. These cells helps Visio understand how the heading is positioned relative to the interior of the container. For example, if the heading is near the left edge of the container then the correct value for the cell is “Right” (regardless of the heading’s angle). The interior of the container is on the right side of the heading.
Visio provides several built-in container shapes in the Insert Container gallery located on the Insert tab of the ribbon. It is possible to override this set of shapes by creating a specially named stencil with other container shapes. Create a stencil named _CONTAIN.vss and place it in the user’s My Shapes folder.
Any shape with User.msvStructureType = “List” is treated by Visio as a List. Note that Lists are also considered to be Containers. They simply have the additional capability of ordering and arranging their member shapes. All of the previously mentioned Container cells apply to list shapes. The following ShapeSheet cells define additional list properties.
There are several ways to add a shape to a list: dragging and dropping the shape, clicking the blue insertion arrow that appears near the list edge or right-clicking an existing member and inserting a shape. Clicking the insertion arrow and right-clicking to insert both use the User.msvSDListItemMaster cell to determine what shape to add to the list. The name of the shape is placed in quotes inside a USE() function, such as USE(“Member shape”). It is also possible to automatically populate the list with some member shapes when the list is first dropped on the page. To do this put the following formula in the EventDrop cell of the list, repeating the DOCMD(2270) once for each member to be added:
Lists have their own cells to govern list membership. Use the User.msvSDListRequiredCategories and User.msvSDListExcludedCategories cells to restrict what shapes can become list members. Because lists are also containers, it is possible for shapes to become container members of the list. The standard User.msvSDContainerRequiredCategories and User.msvSDContainerExcludedCategories cells determine this behavior. By default Visio will attempt to add a shape to a list as a list member, but if that fails it may try to add it as a container member. You should manage both sets of cells to ensure the right results.
Any shape with User.msvStructureType = “Callout” is treated by Visio as a Callout. Callout shapes must also have a control handle with the Controls row named Controls.Association. Visio manages the relationship with the callout’s target shape through this row in the ShapeSheet. The following ShapeSheet cells define additional callout properties.
Visio provides several built-in callout shapes in the Insert Callout gallery located on the Insert tab of the ribbon. It is possible to override this set of shapes by creating a specially named stencil with other callout shapes. Create a stencil named _CALLOUT.vss and place it in the user’s My Shapes folder.
This post gives shape designers the detailed information needed to create their own Containers, Lists and Callouts. Please tell us what you think by using the Send a Smile feedback tool or by commenting on this post.
One of the goals of the Visio 2010 release is to make it easier to create attractive, presentation-quality diagrams. Previously on this blog, we have discussed our improvements to backgrounds, layout, routing, and themes. Visio 2010 also features improvements to the default look of many templates, as well as over 500 newly designed shapes. Below are a few highlights of these changes.
Many Visio 2010 templates feature a new, consistent set of default line, font, and shadow properties that help make diagrams look more modern. Here is an example comparing part of a Visio 2007 flowchart with a Visio 2010 flowchart:
In addition to these general enhancements, below are some specific templates we made significant changes to.
The Landmark Shapes stencil in the Directional Map template has around 30 newly designed shapes. Here are a few:
The Workflow Shapes template also has around 30 newly designed shapes. Here are a few:
Here is a calendar created in Visio 2010, with our newly designed calendar and icon shapes:
Visio 2010’s timeline shapes have a sleek new look. Here is an example:
The above are just a few examples. Here is a more comprehensive list of stencils and templates with new or updated shapes:
We are interested in your feedback on these visual updates. You can use the Send a Smile feedback tool or comment on the blog to let us know what you think.
When creating and maintaining flowcharts, a pain point users suffer from is ensuring that the connectors between shapes look good. Visio introduced the dynamic connector many releases ago to help simplify diagram maintenance. Dynamic connectors in combination with dynamic glue allow Visio to choose the sides of shapes to glue your connectors for the best looking results.
In Visio 2010 we made improvements to Visio's routing engine to address some common flowcharting pain points. (For more on the dynamic connector and why you should use dynamic glue, see this previous post titled "Gluing It All Together". )
Improving Flowchart Readability
Clarity is important in flowcharts. Overlapping connectors flowing in opposite directions can create ambiguity about the meaning of the diagram. It is easy to get into a situation where two connectors appear visually to be connected, but were not explicitly connected by the diagram author. Visio 2010's routing engine detects such ambiguous situations and relocates connectors to actively avoid them.
Consider the example below where I draw two dynamic connectors: one from shape A to B and the other from B to C. In Visio 2007, this leads to an ambiguous drawing, where it appears as if shape A is connected to shape C. Visio 2010 moves the connector between A and B to an alternate side of shape B to resolve the ambiguity.
We made this design change based on user feedback. It scales to handle more than just a few connectors, and allows connectors to overlap when they are flowing in the same direction.
A consequence of this change is that if you open a diagram that was created in older versions of Visio in Visio 2010, as you edit your diagram, you may see connectors relocate to different sides of shapes. Note that Visio doesn't move glue points of connectors that are statically glued.
Relaxing Constraints on Flowchart Direction
Visio flowcharts that use the "Flowchart" routing style have a routing direction, like "Top to Bottom" or "Left to Right". In flowchart routing, this controls what sides of shapes dynamic connectors (mostly) connect to. Strict adherence to this direction can easily lead to situations where a dynamic connector takes a path around a shape with 5 segments.
Using "Top to Bottom" as my routing direction, routes generally exit from the bottom of a shape and connect to the top of the shape, except in cases where shapes line up exactly.
In Visio 2010, we enable dynamic connectors to connect to alternate sides of shapes when the shapes are close to each other.
To strike a balance between having simple looking connectors and still adhering to the flowchart direction, Visio connects to non-standard sides of shapes when two shapes are close to each other in the axis of the routing direction.
As always, we're interested in your feedback on routing, so use the Send a Smile feedback tool or comment on this post to let us know what you think.
A recent newsgroup post asks for an explanation of the cells that get added to a shape when it is converted using the Process Engineering add-on.
The Shape Conversion command in Process Engineering allows you to make any shape work like the built-in Process Engineering shapes. We recognized that customers who made Piping & Instrumentation diagrams often had custom equipment or valves or instruments that they needed to include in the diagram. Shape Conversion modifies a custom shape to make it recognizable by the Process Engineering add-on and match the behaviors of built-in shapes.
You can try this by drawing a rectangle and choosing Shape Conversion from the Process Engineering menu. In the dialog, note that the shape Source is already set to Selected Shapes. Process Engineering can also bring in shapes from other documents or CAD symbols. Then comes the challenging part: you can optionally give the shape a Category and Tag Format. Categories are used to organize the shape in the Component Explorer window. You can choose an existing category or type in a new string. Tag formats are used for automatically labeling and numbering shapes. You must choose from an existing tag format. Visio only offers you choices for Categories and Tag Formats that already exist in the drawing, so if you want your shape to be a piece of Equipment you should drop a built-in Equipment shape on the drawing before converting your custom shape.
After clicking OK, you can open the Shapesheet window to see what changes were made to your shape. The primary change is the set of User-defined cells added to the shape. These cells identify the shape and control its behavior in the diagram.
Here is a brief explanation of each cell:
A GUID (unique identifier) that tells Visio what add-on is managing the shape. All shapes that are used with Process Engineering, need the GUID matching the Process Engineering add-on.
The Category that the shape is assigned to. The shape appears under this name in the Component Explorer.
The current tag name (label & number) for the shape.
The Tag Format name and expression for the shape. Unless the Component Tag has been overwritten, this is the automatically generated label displayed on the shape.
The sequence number for the shape. Visio updates this value when components are renumbered. This value then feeds into the Component Tag.
A Boolean value that determines whether the Component Tag is displayed on the shape. This is manipulated by an Action in the Actions section.
A value that references the global page setting for hiding tags. If tags are hidden at the page level, then the local setting is ignored.
This is a bit flag that controls the layout behavior of the components in the diagram. Mostly these settings determine how the split and heal features in Process Engineering work. Here are the bits:
CAUSES SPLIT = 1 (Splits connector when dropped on connector)
CAUSES HEAL = 2 (Heals connector when deleted)
ALLOWS SPLIT = 4 (Connector splits when shape dropped)
ALLOWS HEAL = 8 (Connector heals when shape deleted)
ALLOWS JUNCTION = 16 (Connector to connector connection)
JUNCTION IN USE = 32 (Temporary state)
The default setting here is 31, which enables all the split and heal and junction behaviors.
There are a few other changes to connection points, action cells and text to complete the conversion. These are straightforward changes, and you can inspect the Shapesheet to see the details.
Tuesday more than 300 customers, partners and Visio community members gathered for Day 1 of Visio Conference 2008. Attendees were treated to an impressive array of partner solutions, product demonstrations and information-filled sessions. To top it all off, attendees got the first sneak peak at the next version of Microsoft Office Visio.
At this point Visio "vNext" is still in an early stage (pre-Alpha), but we wanted to give everyone a glimpse of the fantastic capabilities of the next version and outline our high-level investments. Keep in mind that plans can and do change as we respond to feedback and continue working toward completion. We are publicly showing just a few of the features planned. Here are the three areas where we are concentrating most of our efforts:
Visio "vNext" reinvents the core flowcharting experience in Visio. Flowchart creation is faster and easier than ever. Cross-functional flowcharts in particular are improved. Going beyond a simple drawing canvas, Visio understands the logical structure of the diagram far better. This leads to more advanced process diagramming capabilities that put the user firmly in control over the graphical representation of their processes.
Ease of Use
Visio "vNext" adopts the Office Fluent user interface that you see today in Office 2007 core applications. The Ribbon and Live Preview components in particular take the guesswork out of finding Visio commands and choosing between settings. At the same time Visio improves a wide range of existing features, bringing the results-oriented concepts behind the Fluent UI onto the diagramming surface itself. The Shapes window, layout and AutoConnect are significantly enhanced. Visio is even easier to use and significantly reduces the time needed to create and modify diagrams.
Visio "vNext" introduces server-rendered, data-refreshable diagrams for the first time. Visio Services allows data connected diagrams to be published from Visio to a server and viewed by users directly in their web browser. There are no client bits to install. An API is also provided for creating mashups of diagrams and additional data.
There is far more to talk about with Visio "vNext". In future posts we will begin to provide more details and present screen shots. However, there are also plenty of things to discuss about the current Visio 2007 product. We'll cover both in the coming months. Please stay tuned and be sure to give us your feedback.
Every once in a while a new feature idea comes along that is so unique and compelling that it revolutionizes the way people work. Insert Text Box is not such a feature. Adding text to a diagram is nothing new in Visio. However, usability studies have shown that adding text is one of the more challenging tasks for new users. Thus we added Insert Text Box to Visio 2007 to make diagramming a little more approachable.
Insert Text Box is a menu command that invokes Visio's Text tool. Choosing the command is the equivalent of clicking on the Text tool in the Standard toolbar. We found that new users were not aware of the little 'A' toolbar button. In contrast, most users were aware of PowerPoint's Insert Text Box command, and many would look for a similar command in Visio. Now that command exists.
One significant difference between the Insert Text Box command and the Text tool is that you can only insert one text box at a time with the command. Once the text box is created, Visio automatically switches back to the Pointer tool. With the Text tool you remain in text mode until you manually switch back to the Pointer tool. The one-shot method solves another problem for new users - not knowing about the Pointer tool. Even after users discovered the Text tool, they did not always realize that they had to switch back to the Pointer tool at some point.
Microsoft Office Visio 2007 - now with text box insertion technology. Buy it today.
Our MVP community has been quite busy creating new resouces for Visio. We'd like to highlight a few recent releases here.
In response to a newsgroup discussion on Visio's Network Rack shapes. Chris Roth (Visio MVP and former employee) has released a new shape for displaying rack unit dimensions.
Second, the latest version of the Work Breakdown Structure (WBS) Modeler add-in has been released. To quote from the add-in description:
"The Microsoft Office Visio 2007 WBS Modeler is intended to improve the project planning process by giving the opportunity to generate Project Plans from a Work Breakdown Structure (WBS) using a graphical representation of elements.
The Application enables effective integration of Microsoft Office Visio 2007 with Microsoft Office Project 2007. It provides an approach to visually and graphically create, edit and modify project plans using Visio 2007."
Finally, there are new training materials for Visio 2007 solution development. Here is the summary for the download:
"Gain deeper technical skills around Visio 2007 solution development. The Visio 2007 Solution Development Workshop is a free to download, self paced instructional guide covering the concepts and techniques needed to develop Visio based data visualization solutions. The content of this workshop maps to the main themes of the upcoming Visio MCP examination, makes for an excellent readiness resource and provides partners with the skills to start build data Visualization solutions today."
Data Graphics is a great new feature in Visio 2007 Professional for displaying data on your shapes. One key to the feature's popularity is that you can make or customize your own data graphic callout shapes. There is an article posted on MSDN that covers the full spectrum of customizations possible for Data Graphics. Also check out this post that discusses customizing a data graphic callout. In this post we're going to create a text callout from scratch.
A text callout is one of the four ways that you can visualize data using Data Graphics. It performs the basic role of showing data as text labels on the diagram. In the picture above, there are four text callouts to the left of the Server shape and one below the shape. Some callouts display just a value; others include a field label. The formatting and geometry are as customized as you want to make them.
To create a brand new text callout, we need to create a shape with the look we want and then configure it to work with the Data Graphics feature. For this example we'll do just the minimum steps needed to get things working. We draw a rectangle on the page and open its Shapesheet. In the Shapesheet, we need to insert a User-defined section and a Shape Data section.
There are just two things needed to make this shape a data graphic callout. First, change the row name of the User-defined row to User.msvCalloutType (click on the row name and type "msvCalloutType"). In the Value cell enter "Text Callout" - including the quotation marks here. Second, change the row name of the Shape Data row to Prop.msvCalloutField (click on the row name and type "msvCalloutField").
Visio uses the User.msvCalloutType value to determine where to surface your custom callout shape in the Data Graphics user interface. This shape will appear in the Callouts list in the New Text / Edit Text dialog. Visio populates the Prop.msvCalloutField value (the Value cell in this row) with the data to display at the time the data graphic is applied to a shape on the page. To make it easier to continue building the shape, you may want to put some text in the Value cell to serve as sample data.
What's missing from this shape is the actual display of the data as text. This is typically done using Text Fields. With the shape selected in the drawing window, go to Insert > Field and choose the msvCalloutField in the Shape Data category.
Now we can test this shape. Drag it into the Document Stencil to create a Visio Master shape. Give the master a name.
Now drop a shape on the page and give it some data. The Basic Flowchart Shapes are a good test bed since they have three built-in Shape Data fields. You can right click on the flowchart shape and choose Data > Shape Data to fill in some values. Now right click again and choose Data > Edit Data Graphic to create a new data graphic with your callout.
Because we set the User.msvCalloutType to "Text Callout", we need to go to New Item > Text. In the New Text dialog open the Callout dropdown to see the custom callout shape we made.
Choose the custom callout and then a Data field to display in the callout. Finally click OK twice to see the callout applied to the flowchart shape as a data graphic.
Go ahead and change the Shape Data in the flowchart shape to see it update in the data graphic. Now we have a functioning text callout. What remains is whatever customizations you want to make to enhance the visual appearance of the callout. Perhaps you want to apply formatting or tailor the geometry. Perhaps you want to add configurable settings that the user can select in the New Text / Edit Text dialog. See the MSDN article for more information about adding this functionality. As always, you can look at the callouts that are built into the Data Graphics feature for examples of more sophisticated behaviors.
If you have some suggestions for new data graphic callouts, post a comment. We'd like to hear from you. In the next post we will look at an example for Data Bar callouts.
Visio users and developers often wonder how to distribute their newly created Visio shapes to their colleagues, friends and family (all depends on your friends and family I guess J). Visio offers two mechanisms to publish content, each suited to different situations. This blog entry covers both. But first, an introduction for those new to content creation.
In the Visio world, content refers to shapes, stencils and templates; if you’re familiar with these concepts, please skip to the next section, if not please read on.
· Master shapes are the basic unit of content; they are Visio entities that you can assemble on a drawing page that graphically represent a real-world object or concept. Visio provides a rich set of pre-made master shapes and also enables the creation of custom shapes. To get started authoring shapes, read through this Visio Insights blog posting as well as this set of documents from Microsoft Office Online.
· Stencils are collections of related master shapes that are presented together in the UI. Again Visio provides a large set of pre-made stencils and lets you create your own stencils containing custom made and/or pre-built Visio shapes by following the steps outlined here. Stencils files have a “.VSS” or “.VSX” extension.
· Templates are Visio files that set up the Visio workspace for a particular drawing type by opening appropriate stencils, opening anchored windows and setting page properties such as scale and grid. For example the Space Plan template that ships with Visio opens four stencils, changes paper size and scaling. Instructions on how to create templates may be found here. Template files have a “.VST” or “.VTX” extension.
Publishing a piece of content to Visio adds entry points to the user interface side-by-side with content created by Microsoft. For a stencil this translates into a menu entry added to the File > Shapes fly-out menu while for a template this means an entry in Visio’s startup screen (as seen below) and in the File > New fly-out menu. In this blog entry we will focus on publishing templates to Visio; publishing stencils is quite similar.
The simplest way to publish a template to Visio is to use the Path Discovery method described below:
1. Copy your template and supporting stencils to a known location on a drive.
2. Add the location defined in step 1 to Visio’s “Template Paths”; this tells Visio where to find extra content to populate its startup screen. This can be done manually by following the steps here or may be automated using code that sets the TemplatePaths property on the Visio Application object.
3. Restart Visio – your template should appear in the (Other) category.
The advantages of this approach are:
· It is simple.
· It is supported across most versions of Visio.
It however has a few drawbacks:
· Your users may be subjected to potentially long and error prone manual work.
· Your templates will always end up in the (Other) content category in the startup screen.
· You don’t have any way of repairing content on a user’s machine if it gets damaged.
· You cannot control which language of Visio will load your stencils and templates.
· This approach does not scale well. The Path Discovery publishing method does just that: every time you boot Visio it searches a user’s hard drive for content files – an expensive operation.
Sharing templates through Path Discovery is good for small scale content deployments as well as deployments to older versions of Visio.
The PublishComponent system introduced in Visio 2003 lets developers use Windows Installer technology for template distribution to register their content with Visio in a richer and more robust way. The main advantages of this method are quite interesting:
· The Windows Installer setup wizard is familiar to users and easy to use.
· You may choose where your content appears in the File > Shapes or startup screen hierarchies.
· You benefit from Windows Installer repair, install-on-demand and add/remove features.
· You may choose what language versions of Visio to publish your content to.
· The approach scales well: Visio only rebuilds its content cache, a moderately expensive operation, when new content is published.
· The approach is tried and tested since the product publishes its own content this way since the 2003 release.
That said, using the Publish Component system is:
· A little more complicated than the Path Discovery method.
· Will only work for Visio 2003 and or later.
To use this method you’ll need Visual Studio .NET or later, the Visio 2003 SDK (or the Visio 2007 Beta SDK) and the following steps:
If you installed the package as it is; Visio would not discover the files the MSI installed. To notify Visio on the whereabouts of these files, the next thing to do is populate the PublishComponent table of the MSI produced above with registration data. Once installed, this extra information will force Visio to rebuild its content cache and incorporate and display the new templates and stencils.
The extra information you need to add may be found here. Be warned however, it is not for the faint of heart to enter this data manually. For those of us who would rather not spend their Saturday night writing MSI tables entries you can follow the steps below using the PublishComponent tool shipped in SDK to populate the appropriate MSI table easily:
To make the changes described above double click on each entry to bring up the “Template Information” dialog seen below, or its counterpart the “Stencil Information” dialog.
The MSI can now be distributed; Windows Installer and Visio will do the rest. Although we haven’t discussed it here, the same techniques can be used to publish add-ins and help files. For the curious, use ORCA and the guidance in the KB article above to understand what modifications the tool made to the MSI.
As a final note, you’ll see that the template you just published shows up in the startup screen, however the template preview is blank; I’ll leave it up to crafty souls out there to figure out how to get template preview’s this working… OR you could stay tuned to the Visio Insights blog for more info =).
This post will be a little experiment to try out file attachments on the blog.
When customers send files to us, we often want to get a general understanding about the drawing contents. This is common in scenarios where customers are concerned about performance or file size. Visio drawings may be carrying some excess baggage along.
In addition to shapes on the page, a Visio document contains information about master shapes, styles, layers, fonts, colors, data and other items. These collections of information are used to accurately present the shapes on the page. However, they do not automatically get purged when shapes are deleted from the diagram.
Take the simple example of a flowchart. If you drag a Process shape onto the drawing page, Visio adds a copy of the Process master shape to the document and places an instance of this master shape on the page. If you delete the Process shape from the page, the master shape remains. Over time unused master shapes pile up. Normally this is no big deal, but some shapes contain large bitmaps or other complex information that will quickly increase file size.
Before you go out and delete every master shape from your document, keep in mind that master shapes are highly efficient when they are actually used in the drawing. If you took a drawing with many copies of the same shapes and then deleted the master, you would find the resulting document much larger and slower.
The attached DrawingAnalyzer.vsd document is a handy little tool written in VBA for counting the shapes in a drawing and determining whether there are unused master shapes. Also the tool counts shapes on the page with no master shape, and it keeps track of the level of grouping among shapes. More nested groups mean much slower performance.
To use the tool, open the file in Visio along with any other document you want to analyze. Make sure the document to be analyzed is in the active window. Then go to Tools > Macro > DrawingAnalyzer > ThisDocument > GetDrawingStats. Then open the VBA Editor (Alt+F11) and look in the Immediate Window (Ctrl+G) at the output. Here's a sample result:
Total Pages: 3 Total Shapes: 495
Top Level Shapes: 11 Group Shapes: 92 Max Nesting Depth: 3 Total Masters: 13 Unused Masters: 0 Shapes w/o Masters: 36 Total Patterns: 0 Unused Patterns: 0 Total Styles: 9
A top level shape is a shape directly on the page. All other shapes are found inside of groups. In this example, there are only 11 shapes spread across the 3 pages in the drawing. However, the total number of shapes is 495, meaning there are lots of shapes inside groups. There are even groups inside groups inside groups as evidenced by the maximum nesting depth of 3. This is not terribly efficient. All 13 master shapes in the document are used in the drawing, so that is good. 36 shapes have no master. If any of these shapes are similar, it would be more efficient to create a master shape for them.
The DrawingAnalyzer.vsd file is saved in Visio 2000/2002 format. Please post a comment if you have difficulties getting the file. As we said, this is a test.
Today is a holiday in the US, so we're republishing this topic from a newsgroup post not too long ago.
Summary: You can add the User.visEquivTitle cell to your shape and provide a string that will display as a tooltip in HTML web output. The shape must also have at least one custom property for the tooltip to be visible.
Steps: 1) Select the shape in your drawing that you want to add a web tooltip for 2) Go to Window > Show Shapesheet 3) Go to Insert > Section, check User-defined cells and click OK 4) In the newly created section, click on the row name User.Row_1 to select the title of the row 5) Type visEquivTitle and press Enter - you should now see User.visEquivTitle for the row 6) In the Value cell of that row, enter the text you want to display surrounded by quotes (e.g. "Hello World") 7) If you instead want to display the same tooltip as the Shape ScreenTip enter =Comment (no quotes) 8) Go to Insert > Section, check Custom properties and click OK 9) You can fill in the custom property Label and Value if you want this information to be visible 10) If you don't want the custom property to be visible, enter TRUE in the Invisible cell 11) Close the Shapesheet window and repeat for any other shape you like 12) Choose File > Save as Web Page to create the HTML output
As you can see this is a bit involved. The capability was designed more as a developer feature than an end user feature. We recommend tying the Shape ScreenTip to the User cell so that you see the same tooltip in both Visio and the web output. It should also be possible to use Macro Recorder to automate these steps. If your shape has a custom property but does not have the User.visEquivTitle cell, Visio will display the shape's text in a tooltip instead.
Visio makes it easy for users to place shapes anywhere and provides connectors for maintaining connections between shapes. However, as diagrams get more complicated, users often look to Visio for help organizing shape placement and connector routing on the page. Unfortunately, while Visio's automatic layout functionality is quite powerful, many times the results are not good enough without tweaking the layout settings. In this post we'll look at one such scenario and try making a few changes to improve the final results.
Here is a custom shape with several connection points on each side. Connectors are intended to glue to these points on the shape.
A diagram is created using this shape and connectors are added.
We now would like Visio to rearrange the shapes and reroute the connectors to create a cleaner, more readable diagram. Choosing Shape > Re-layout Shapes gives this result:
This result is not ideal. There are still overlapping connectors and too many bends. Visio is actually constrained by the way the connectors were glued to the shapes. The traditional way to glue connectors is to drag the end of the line to a connection point on the shape. This creates what is known as static glue in Visio. The connector remains associated with that connection point. Static glue has drawbacks for layout because it prevents Visio from routing to the nearest side of the shape. An alternative is using dynamic glue. To glue using dynamic glue, drag the end of the line to the center of the shape. A red outline rectangle will appear to indicate dynamic glue. The resulting red glue square has a slightly different look as well.
By switching all the connections over to dynamic glue, Visio can choose more efficient routes for the connectors. However, now Visio routes to locations on the shapes that we do not want. Our custom shape is not supposed to allow connections on the top or bottom.
There is a Shapesheet cell that allows us to set some restrictions on dynamic glue so that Visio will not choose any arbitrary location to connect. The Shape Layout section has a cell named ShapeFixedCode that determines how connections can be made to a shape. By setting ShapeFixedCode to 64 on the custom shape we can force Visio to connect at connection points.
Now the automatic layout keeps the connectors glued to the connection points. Note that the glue style is still dynamic glue. Visio is free to choose which connection point is used for each connection. The result is better but still not ideal. There are still too many bends in the connectors as Visio must work in and around the shapes.
One final change can clean this layout up. Each drawing page has a default layout spacing, but the shapes you use in the drawing may not be suitable for that default. In this example, the default drawing spacing is 0.375 in. while the custom shape size is 1.25 in. x 1 in. That pushes the shapes too close together. By increasing the spacing between shapes, Visio can find better routes for the connectors. This is done in the Shape > Configure Layout dialog.
The end result is a much simpler arrangement with clean connector routes.
Dynamic glue adds flexibility to Visio's layout and routing optimizations and will result in a better looking diagram. The tradeoff is the inability to specify particular connection points for connectors. Visio assumes all connection points are equally valid. Hopefully the techniques presented in this post help you get better layout results. It is unfortunate that Visio's automatic layout needs this much tweaking to get good results, but it is challenging for a layout engine to produce optimal results across a huge variety of drawing types. As always, tell us your pain points, and we will try to address them in the future.
Shape design is somewhat of an art in Visio. There are so many things that go into creating professional-looking content that a certain level of expertise is required. One of the goals of the Visio Insights blog is to provide that expertise in an understandable format. Another goal is to demonstrate best practices to help you use Visio in the most effective manner. This week we will demonstrate shape construction techniques by creating a new shape from scratch.
Our example is a digital clock shape. The numerals in the clock – the digits – are drawn in geometry instead of text. This allows us to be more creative with the appearance of the digits. We want the digit to appear as it is shown in a Liquid Crystal Display.
Today’s post focuses on ways to use the power of Visio to create shape geometry. There are several approaches to constructing geometry. You can use Visio’s drawing tools to manually draw the lines and arcs needed for the shape. This works well for simple geometry, but the tools are not suitable for complex geometries. You can also build geometry using the Shapesheet window by entering the actual formulas in the Geometry sections. This approach is very precise but can be extremely slow and difficult to get things right. A third approach is to build a complex shape by assembling it from simpler pieces. This is the simplest approach because it makes Visio do the heavy lifting to create the final geometry.
Let’s construct a shape to represent a digit for our clock using this assembly approach. A digit is composed of seven individual polygons, which are shown or hidden to generate each possible numeral. These polygons have tiny gaps separating them. Also a slight rounding is applied for aesthetics. We start by drawing a rectangle 1/2 in. wide by 1 in. tall. Then we use the Offset command found in the Shape > Operations menu to create two additional rectangles 1/16 in. away from the original shape. The outermost rectangle is not needed, so it is deleted. We select the remaining two rectangles and use the Subtract command from the Shape > Operations menu to create a single shape with its middle removed.
The crossbar is added by drawing a rectangle 1/2 in. wide by 1/16 in. tall and positioning it in the center of the existing shape. A composite shape is created by selecting both shapes and choosing the Union command from Shape > Operations. Note that commands such as Union and Subtract destroy the selected shapes and generate a brand new shape with the composite geometry. For this reason, you should create the geometry of a shape before moving on to other aspects like formatting or behavior.
Next we need to segment the shape into seven pieces with small gaps in between. We draw lines in the places where we want the gaps to be located. The lines extend beyond the shape geometry to facilitate the next shape operation. Getting the lines in exactly the right place may require zooming in very close. Otherwise Visio’s snapping behavior may prevent you from placing your cursor where you want it. Once all the lines are drawn they need to be selected. This is accomplished by selected all the shapes and then Shift+clicking on the digit shape to deselect it. Then the Offset command is run with a spacing of 0.015 in.
The offset lines serve as break points where the underlying digit shape must be segmented. The segmenting is done using the Fragment command in Shape > Operations. This command uses all the selected geometry to define simple closed polygons. We can apply a green fill to the resulting shapes to better see them. The inside squares are deleted first. Then the tiny corner polygons are deleted, leaving only the seven segments for our digit.
We now have seven individual shapes that make up our digit. By selecting the shapes and choosing the Combine command in Shape > Operations, the seven shapes are converted into a single shape containing seven geometry sections. This is a much more compact representation of the digit - decreasing file size and improving performance. Corner rounding of 0.02 in is applied to the shape as a final touch.
While there were several steps to get to the end result, we never had to do any complicated drawing or Shapesheet formula entry to construct this shape. Two rectangles were drawn for the basic digit outline. Then eight lines were drawn to define break points for the segments. Visio’s shape operation commands did the rest of the work. In the next post, we’ll add some smarts to this digit shape and use it to build up our digital clock.