How to Create Grouped Shapes and Custom Menus in Visio
Question details
The user wants to create a customized shape with grouped components and a right-click context menu to display different options, similar to advanced relay stencils.

- Product
- Microsoft Visio
- Device & OS
- not provided
- Scenario
- Designing dynamic custom smart shapes or relay stencils that require user-selectable data and specific right-click behaviors.
- Observed behavior
- The user needs to replicate the behavior of a specialized Visio shape that provides dynamic relay types and voltages through a custom context menu.
Before modifying complex shapes, ensure you have Developer Mode enabled in Visio by going to File > Options > Advanced and checking 'Run in developer mode'.
Inspect Grouped Shapes Using Document Explorer
Use the Document Explorer to safely view and manage the components of a grouped shape without breaking its internal references.
In Visio, stencils contain masters, and masters contain shapes. It is critical to group shapes rather than stencils. Furthermore, you should avoid ungrouping a complex master shape because doing so can permanently destroy internal references, ShapeSheet logic, and other critical design information.
Navigate to File > Options > Advanced. Scroll down to the General section and check 'Run in developer mode' to reveal advanced tools.
Go to the Developer tab on the ribbon and click on 'Document Explorer' to open a hierarchical tree view of your Visio file.
Expand the 'Masters' folder in the Document Explorer, locate your specific stencil master, and expand it to safely view the grouped shapes and components inside.

Add Custom Menus via Visio ShapeSheet
Program custom right-click options for your smart shape using the Visio ShapeSheet environment.
Discover WPS Office for Easy Document and Flowchart Creation
While advanced ShapeSheet programming is unique to Visio, WPS Office provides a free, lightweight, and highly compatible alternative for everyday document creation, basic drawing, and flowcharting. Enjoy a familiar interface and seamless migration without expensive subscription fees.
- 1. Open a WPS Office Application: Launch WPS Writer or WPS Presentation to begin a new document or slide.
- 2. Insert and Arrange Shapes: Navigate to the Insert tab, click Shapes, and select the flowcharts or objects you need to draw.
- 3. Group Your Objects: Hold the Shift or Ctrl key to select multiple shapes, right-click, and select Group to manage them as a single object.

Frequently Asked Questions
Why shouldn't I ungroup complex shapes in Visio?
Ungrouping complex shapes can destroy critical internal references, ShapeSheet data, and specific design configurations. It is better to use the Document Explorer to view and edit internal components without breaking the group structure.
What is the difference between a master shape and a document copy?
A master shape is the original design stored inside a Visio stencil. When you drag that master onto a drawing page, Visio creates a document copy (or instance) of that shape, which inherits properties from the master.
How do I access the ShapeSheet in Microsoft Visio?
To access the ShapeSheet, you must first enable Developer Mode in File > Options > Advanced. Once enabled, you can select any shape, right-click it, and choose 'Show ShapeSheet' from the context menu.




