Identify nodes ext in SmartArt on PwerPoint slide that contains many shapes. RRS feed

  • Question

  • Hi All:

    I want to identify the text in the nodes of a Basic Block List SmartArt shape on a PowerPoint slide that contains other shapes. The code below isn't working for me. Any suggestions gratefully appreciated.

     Sub SmartArtText()
         Dim shp As shape
         Dim oSubShape As shape
         Dim x As Long
        With ActivePresentation.Slides(2)
            With shp.SmartArt
            For i = 1 To .Nodes.Count
                'MsgBox .Nodes.Count
                MsgBox .Nodes(i).TextFrame.TextRange.Text
            Next i
            End With
        End With
    End Sub

    Tuesday, May 10, 2016 4:13 PM


  • Hi,

    To get the text of group items in a smart art, we need to use the GroupItems property. Here is the code for your reference:

     For Each gi In Application.ActivePresentation.Slides(1).Shapes(1).GroupItems
        Debug.Print gi.TextFrame.TextRange.Text
    Regards & Fei

    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Wednesday, May 11, 2016 9:54 AM