Results 1 to 4 of 4
  1. #1
    4 Star Lounger
    Join Date
    Jan 2001
    Location
    Illinois
    Posts
    551
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Code to Break Links (Office xp, w2000)

    Is there vba or vb code that will break all the links in a ppt file? thanks

  2. Get our unique weekly Newsletter with tips and techniques, how to's and critical updates on Windows 7, Windows 8, Windows XP, Firefox, Internet Explorer, Google, etc. Join our 480,000 subscribers!

    Excel 2013: The Missing Manual

    + Get this BONUS — free!

    Get the most of Excel! Learn about new features, basics of creating a new spreadsheet and using the infamous Ribbon in the first chapter of Excel 2013: The Missing Manual - Subscribe and download Chapter 1 for free!

  3. #2
    4 Star Lounger
    Join Date
    Dec 2000
    Location
    Quakertown, PA, Pennsylvania, USA
    Posts
    517
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Code to Break Links (Office xp, w2000)

    You should be able to Cut, then Edit-Paste special as a picture and remove the link. If you know VBA at all, record this step, and then make it loop until... I don't know VBA enough to create that code for ya.

  4. #3
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: Code to Break Links (Office xp, w2000)

    If you're looking to remove the links, leaving just the text to which they were attached, here is a VBA procedure that will do that. I added this code by opening a presentation, popping up the VB Editor (Alt-F11), then choosing Insert Module.

    <pre>Sub RemoveLinks()
    If MsgBox("Remove hyperlinks from the active presentation?", vbQuestion + vbYesNo) _
    <> vbYes Then Exit Sub
    Dim hypLink As Hyperlink, sldIndivSlide As Slide
    With ActivePresentation
    If .HasTitleMaster Then
    If .TitleMaster.Hyperlinks.Count > 0 Then
    For Each hypLink In .TitleMaster.Hyperlinks
    hypLink.Delete
    Next
    End If
    End If
    If .SlideMaster.Hyperlinks.Count > 0 Then
    For Each hypLink In .SlideMaster.Hyperlinks
    hypLink.Delete
    Next
    End If
    For Each sldIndivSlide In .Slides
    If sldIndivSlide.Hyperlinks.Count > 0 Then
    For Each hypLink In sldIndivSlide.Hyperlinks
    hypLink.Delete
    Next
    End If
    Next
    End With
    End Sub</pre>


  5. #4
    4 Star Lounger
    Join Date
    Jan 2001
    Location
    Illinois
    Posts
    551
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Code to Break Links (Office xp, w2000)

    Thank you so much. I can use this code for hyperlinks for sure. I wasn't clear, however, that the links i need to break are links from Excel to Powerpoint. The only way i can find to change them is to go into links and one by one break the links. When i try to record a macro it won't give me any code. Hope this clarifies things. thanks again.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •