Answers for "PPTX contents page"

0

PPTX contents page

Sub TableOfContentUpdater()
    Dim pTableOfContent As Slide
    Set pTableOfContent = ActivePresentation.Slides(2)
    
    For Each pHyperLink In pTableOfContent.Hyperlinks
        Dim pLinkNumber As String
        Dim pLinkedSlide As Slide
        pLinkNumber = Left(pHyperLink.SubAddress, InStr(pHyperLink.SubAddress, ",") - 1)
        pHyperLink.TextToDisplay = ActivePresentation.Slides.FindBySlideID(CLng(pLinkNumber)).SlideIndex
    Next pHyperLink
End Sub
Posted by: Guest on July-05-2021

Browse Popular Code Answers by Language