Questions tagged [visio]

Visio is a diagramming tool included as part of the Microsoft Office suite. This tag is only for questions on programming against Visio objects or files—also tag with VBA.

Visio is a diagramming tool included as part of the Microsoft Office suite, though it is usually acquired separately. It is used to create documents such as flowcharts, organizational charts, network topologies, and software architecture diagrams. Visio includes a development environment known as the ShapeSheet and an API which can be used to develop diagraming and data visualization applications.

Ask programming-related questions about Microsoft Visio (ShapeSheet, API, UML, flow charts, database diagrams, etc.) here on Stack Overflow. For non-programming applications of Visio and for general Visio support, consider if your question might be a better fit on Super User.


Documentation:

1485 questions
2
votes
0 answers

Visio 2016 - AxMicrosoft.Office.Interop.VisOcx - strange behaviour while saving on network

I've build an own application based on Visio 2010 which implements the visio drawing frontend by using AxMicrosoft.Office.Interop.VisOcx. The application works fine over many years with Visio 2010. Now i want to use my application with an installed…
2
votes
1 answer

Copying a visio page and pasting it in excel as an image

I'm trying to copy all shapes in a visio page and paste it in Excel as an image. The image should be a close replica of the visio drawing. Looking for Excel vba script to do this. I'm able to open visio, access shapes information etc, but stuck in…
2
votes
1 answer

Get relative shape location in visio

I am generating a shape report to list x,y locations of all my shapes. The report includes "Display Text", "X location" and "Y location". The "X location" and "Y location" are equivalent to the PinX and PinY properties in the shape sheet. However…
Martin
  • 120
  • 1
  • 10
2
votes
1 answer

Free program to view .sequencediagram files

Is there a free program to view ".sequencediagram" files generated by VS2010 Ultimate? I have generated some and want to share them with my team, but do not want to copy and paste all of them into images files.
2
votes
1 answer

Visio VBA: How to register to mouse double click event on a shape in VB code

I have two questions: Is there a way to change the shape's ShapeSheet (spreadsheet) parameters via a VBA code? More precisely, I need to change the EventDblClick parameter value in the shape's ShapeSheet. Is there another way to register a mouse…
Dudi72
  • 59
  • 5
2
votes
1 answer

Cannot run visio macro using python

I'm trying to run a visio macro using python. I got this so far which doesn't work i get error: AttributeError: .Run when calling doc.Application.Run if os.path.exists("Drawing1.vsdm"): visio =…
Klemen
  • 23
  • 4
2
votes
1 answer

Visio vba Connecting a dynamic connector to a connection point

I'm having some troubles connecting a linked dynamic connector which actually connects to a pre-defined connection point instead of just connection to the top. My master has some text boxes at the left side and some at the right side. When I auto…
dec0yable
  • 87
  • 13
2
votes
1 answer

Visio macro to save a macro-free file

I have a series of complex charts to draw, so I have written a macro that takes a set of instructions from a CSV file and draws them appropriately. This works, but I need to manually save the produced page as a .vsdx file (i.e. without my macro…
David Fulton
  • 737
  • 7
  • 16
2
votes
2 answers

VBA in MS Visio - highlighting connectors of selected shape

After selecting a shape (f.e. square or more squares) all the connectors glued to this shape would highlight red, yellow whatever. The found code below is not working for me, any advice? (I am not coder, so please have patience with me) Set shpAtEnd…
Jeame
  • 49
  • 1
  • 6
2
votes
2 answers

How do I draw a rounded rectangle in Visio VBA?

I know I can draw a rectangle in Visio VBA using the Shape.DrawRectangle method, which is basically equivalent to using the "rectangle" tool in the manual UI. However, the Visio shapes panel also includes a "rounded rectangle". How can I draw a…
Adam Burley
  • 5,551
  • 4
  • 51
  • 72
2
votes
1 answer

VSTO Visio 2010 Handling MarkerEvent

I'm trying to handle the MarkerEvent, however I get a compliation error saying my method doesn't match the delegate. Application.MarkerEvent += new Visio.EApplication_MarkerEventEventHandler(Application_MarkerEvent); //... private void…
Mike Borozdin
  • 1,138
  • 3
  • 14
  • 32
2
votes
1 answer

Set user-defined cell value in Visio document shape sheet from a macro.

I added a row to the User-defined Cells section of the main Visio document shape sheet called User.Revision. I can use the value in the drawings by adding a field set to use a Custom Formula =TheDoc!User.Revision. I would like to have a macro to set…
Mark Di Val
  • 81
  • 1
  • 7
2
votes
1 answer

VISIO VBA Get a collection of all Shapes in a group

I want to get a collection of all shapes that are in a certain group. Shapes in the group may be a group themselves so I (think I) need a recursive function to get every shape. This is my code: Function getAllShapes(shp As Shape) As Collection …
ksbawpn
  • 302
  • 4
  • 19
2
votes
1 answer

Visio Change Shape Data/Properties with VBA

for a project I am creating a UserForm that reads values from textboxes and generates Shapes with the data. So after dropping a shape I want to change the Shape Data rows, for example "Prop.SO_Name". When I use shp.CellsU("Prop.SO_Name").FormulaU =…
ksbawpn
  • 302
  • 4
  • 19
2
votes
1 answer

Export data from Visio Shapes using VBA

I want to model something similar to a (hyper-)graph in MS Visio 2016 Professional and then export the data of the shapes to csv to further work with it. I am trying to make a VBA Script that goes through all the shapes on the sheet and writes the…
ksbawpn
  • 302
  • 4
  • 19