OfficeTips Home || VBA Section || General Section || Download Section || Privacy Policy

Disable the "Update links" dialog box

If you work on a presentation which has linked files then every time the presentation is opened for editing you will encounter the Update Links dialog box with the following message, "The presentation <filename> contains links. Do you want to update now?". You might want to temporarily disable this message. First of all let use understand why does the message pop-up. Whenever you insert a linked file into a presentation, PowerPoint sets the AutoUpdate property of the linked file to Automatic by default. This AutoUpdate Property of the object determines the manner in which PowerPoint Updates the information of the linked file within the presentation. When it is set to Automatic PowerPoint will update it whenever the presentation is opened. When set to manual. PowerPoint will update the information only when the user double-clicks on the object to update the information. By setting the AutoUpdate property of the object to Manual mode, the Update links dialog box can be disabled. Given below are two ways doing so.

 

a) Use the Edit | Links option: In the Links window, click on each link in the list and set it to Manual as show in the figure below:

 

 

b) Use a VBA Macro: VBA does provide the option to define the manner of updating when you insert a linked object using the AutoUpdate property. A macro is useful when you have a lot of linked files. The macro given below sets all linked objects to manual update. If you want to change it to automatic edit the UpdateMode macro to call SetLinksToAutomatic


' --------------------------------------------------------------------------------
' Copyright ©1999-2018, Shyam Pillai, All Rights Reserved.
' --------------------------------------------------------------------------------
' You are free to use this code within your own applications, add-ins,
' documents etc but you are expressly forbidden from selling or
' otherwise distributing this source code without prior consent.
' This includes both posting free demo projects made from this
' code as well as reproducing the code in text or html format.
' --------------------------------------------------------------------------------

 

Sub UpdateMode()
    Dim lCtrA As Integer
    Dim oPres As Object 'Presentation
    Dim oSld As Slide
    Set oPres = ActivePresentation
    With oPres
        ' Process shapes on the slides
        For Each oSld In .Slides
            Call SetLinksToManual(oSld)
        Next
        ' Process shapes on the slides masters
        If Val(Application.Version) > 9 Then
            'For versions 2002 and later with multiple master support
            For lCtrA = 1 To .Designs.Count
                If .Designs(lCtrA).HasTitleMaster Then
                    Call SetLinksToManual(.Designs(lCtrA).TitleMaster)
                Else
                    Call SetLinksToManual(.Designs(lCtrA).SlideMaster)
                End If
            Next
        Else
            ' Version 97/2000
            Call SetLinksToManual(.SlideMaster)
            If .HasTitleMaster Then
                Call SetLinksToManual(.TitleMaster)
            End If
        End If
    End With

End Sub
Sub SetLinksToManual(oSlideOrMaster As Object)
    Dim oShp As PowerPoint.Shape
    For Each oShp In oSlideOrMaster.Shapes
        If oShp.Type = msoLinkedOLEObject Then
        'Set the link to manual update mode
           oShp.LinkFormat.AutoUpdate = ppUpdateOptionManual
        End If
    Next oShp
End Sub
Sub SetLinksToAutomatic(oSlideOrMaster As Object)
    Dim oShp As PowerPoint.Shape
    For Each oShp In oSlideOrMaster.Shapes
        If oShp.Type = msoLinkedOLEObject Then
        'Set the link to automatic update mode
           oShp.LinkFormat.AutoUpdate = ppUpdateOptionAutomatic
        End If
    Next oShp
End Sub


Save the presentation. Close the presentation. Open it again. This time you will not be prompted with the "Links Update" box. Remember all the links have to be set to Manual update to prevent the box from appearing.


 


 

 

Copyright 1999-2018 (c) Shyam Pillai. All rights reserved.