Update Links In Powerpoint

  • I have excel links in powerpoint that are set to manual update. How can I get them to update using VBA? (i.e. the equivalent of going to Edit, Links, selecting all links and clicking Update Now.). I tried using


    Code
    1. activepresentation.updatelinks


    but it didn't work.

  • Re: Update Links In Powerpoint


    I would have thought your code would work but it doesn't!


    Maybe this will

    Code
    1. Sub linkupdate()
    2. Dim osld As Slide
    3. Dim oshp As Shape
    4. For Each osld In ActivePresentation.Slides
    5. For Each oshp In osld.Shapes
    6. If oshp.Type = msoLinkedOLEObject Then
    7. oshp.LinkFormat.Update
    8. Next oshp
    9. Next osld
    10. End Sub
  • Re: Update Links In Powerpoint


    Quote from JWilson;397297

    I would have thought your code would work but it doesn't!


    Maybe this will

    Code
    1. Sub linkupdate()
    2. Dim osld As Slide
    3. Dim oshp As Shape
    4. For Each osld In ActivePresentation.Slides
    5. For Each oshp In osld.Shapes
    6. If oshp.Type = msoLinkedOLEObject Then
    7. oshp.LinkFormat.Update
    8. Next oshp
    9. Next osld
    10. End Sub



    so I know this thread is really old, but I am trying to do this in powerpoint 2010 and this code isn't working, any thoughts?

  • Re: Update Links In Powerpoint


    I'm having the same issue and none of these solutions seem to work. I would just set the links to 'automatic', but I get an error message of "The source application is busy and can't respond immediately" when running the vba which combines refreshing data queries/pivot tables and updating the links in powerpoint. Is there a way to update the links via VBA if they're set to manual in PowerPoint? This is driving me insane.


  • Re: Update Links In Powerpoint


    Quote from blokey;663507

    I'm having the same issue and none of these solutions seem to work. I would just set the links to 'automatic', but I get an error message of "The source application is busy and can't respond immediately" when running the vba which combines refreshing data queries/pivot tables and updating the links in powerpoint. Is there a way to update the links via VBA if they're set to manual in PowerPoint? This is driving me insane.


    OK, I *think* I may have solved my own problem, by changing the links to manual update before the queries run and the pivot tables update, and then right back to automatic when complete, then running UpdateLinks. I can't take credit for any of the code, it's a cross between a few different sources (MVPs, http://www.recursivecreativity…efresh_Linked_Objects.txt, and maybe another place or two). Please excuse any code bloat/inefficiencies as I'm not a developer.