Visio Guy

Visio Discussions => General Visio => Topic started by: JohnVisioMVP on February 19, 2021, 12:56:23 AM

Title: RecordType in the shapesheet
Post by: JohnVisioMVP on February 19, 2021, 12:56:23 AM
Does anyone know of an enumeration list for the RowTypes in the Shapesheet.
https://docs.microsoft.com/en-us/office/vba/api/Visio.visrowtags lists the ones in the Geometry section, but I can not find any description of RowTypes not in Geometry sections.
For example...
In Section 1 135, 155, 156, 157, 164, 167, 243, 245
In Section 2 131

I found the values by running
Sub RTTest()
Dim curRow As Integer, nrows As Integer, RowCnt As Integer, SectNo As Integer, VsoShp As Visio.Shape
For Each VsoShp In ActivePage.Shapes
    For SectNo = 1 To 255
        nrows = VsoShp.RowCount(SectNo)
        If VsoShp.SectionExists(SectNo, visExistsAnywhere) Then
            Select Case SectNo
            Case visSectionObject
                For curRow = 1 To 512
                    If VsoShp.RowExists(SectNo, curRow, 1) Then
                        Debug.Print SectNo; vbTab; VsoShp.RowType(SectNo, curRow)
                    End If
                Next curRow
             Case Else
                For curRow = 0 To (nrows - 1)
                    Debug.Print SectNo; vbTab; VsoShp.RowType(SectNo, curRow)
                Next curRow
            End Select
        End If
    Next SectNo
Next VsoShp
End Sub

Title: Re: RecordType in the shapesheet
Post by: JohnVisioMVP on February 19, 2021, 09:35:31 PM
I did blog about the question https://johnvisiomvp.ca/2021/02/19/visio-rowtype/