A family of Microsoft relational database management systems designed for ease of use.
In VBA, insert a UserForm (you can then delete it if you want to) because it will add a reference the DataObject.
(I'm too lazy to work out which library you need).
Copy and past the sub function below ...
You will end up with text in your clipboard that can be pasted into Excel into rows and columns.
Public Sub ListShapesOnLayers()
Dim pag As Visio.Page
Dim sel As Visio.Selection
Dim shp As Visio.Shape
Dim dataObj As DataObject
Dim text As String
Dim lyr As Visio.Layer
text = "Page" & vbTab & "Layer" & _
vbTab & "ID" & vbTab & "Name" & _
vbTab & "Text"
For Each pag In ActiveDocument.Pages
If pag.Type = visTypeForeground Then
'Debug.Print pag.Name
For Each lyr In pag.Layers
'Debug.Print , lyr.Name
Set sel = pag.CreateSelection(visSelTypeByLayer, 0, lyr)
If sel.Count > 0 Then
For Each shp In sel
If Len(shp.Characters.text) > 0 Then
text = text & vbCrLf & pag.Name & vbTab & lyr.Name & _
vbTab & shp.ID & vbTab & shp.Name & _
vbTab & shp.Characters.text
End If
Next
End If
Next lyr
End If
Next
Set dataObj = New DataObject
dataObj.Clear
dataObj.SetText text
dataObj.PutInClipboard
MsgBox "Paste the text into Excel or somewhere", vbInformation
End Sub