Skip to content

Latest commit

 

History

History
61 lines (38 loc) · 1.49 KB

Visio.Shape.Paths.md

File metadata and controls

61 lines (38 loc) · 1.49 KB
title keywords f1_keywords api_name ms.assetid ms.date ms.localizationpriority
Shape.Paths property (Visio)
vis_sdr.chm11214055
vis_sdr.chm11214055
Visio.Shape.Paths
8a179059-7cab-728a-c7b8-a4d8b31476ee
06/08/2017
medium

Shape.Paths property (Visio)

Returns a Paths collection that reports the coordinates of a shape's paths in the coordinate system of the shape's parent. Read-only.

Syntax

expression. Paths

expression A variable that represents a Shape object.

Return value

Paths

Example

This Microsoft Visual Basic for Applications (VBA) macro places a shape on the page, retrieves its Paths collection, and then uses the Points property of the Path object to return an array of points that defines a polyline approximating the Path object.

 
Public Sub Paths_Example() 
 
 Dim vsoShape As Visio.Shape 
 Dim adblXYPoints() As Double 
 Dim strPointsList As String 
 Dim intOuterLoopCounter As Integer 
 Dim intInnerLoopCounter As Integer 
 
 Set vsoShape = ActivePage.DrawOval(1, 1, 4, 4) 
 
 For intOuterLoopCounter = 1 To vsoShape.Paths.Count 
 
 vsoShape.Paths(intOuterLoopCounter).Points 1#, adblXYPoints 
 For intInnerLoopCounter = LBound(adblXYPoints) To UBound(adblXYPoints) 
 strPointsList = strPointsList & adblXYPoints(intInnerLoopCounter) & Chr(10) 
 Next intInnerLoopCounter 
 
 Next intOuterLoopCounter 
 Debug.Print strPointsList 
 
End Sub

[!includeSupport and feedback]