Deleting comments from Visio diagram in VBA

M

Marcw

I haven't been able to find any sample code to remove comments from a
Visio diagram. Can someone please help?

Thanks in advance.

Marc
 
M

Marcw

Thanks. I had run the macro recorder but wasn't sure how to remove all
of the comments mainly by being lazy. I have no imlemented the
following which appears to work as desired:

For Each myVisioPage In myVsoApp.ActiveDocument.Pages
If myVisioPage.PageSheet.SectionExists(Visio.visSectionAnnotation,
Visio.visExistsAnywhere) Then
For nCounter = 0 To
myVisioPage.PageSheet.RowCount(Visio.visSectionAnnotation) - 1
myVisioPage.PageSheet.DeleteRow visSectionAnnotation, 0
Next nCounter
End If
Next

Marc
 
Top