PowerPoint) (LinkFormat 物件

含有套用至連結 OLE 物件、連結圖片及 IIRC 媒體物件的屬性及方法。

範例

使用 LinkFormat 屬性可傳回 LinkFormat 物件。 下列範例會循環查看使用中簡報內的所有投影片上的所有圖案並將所有連結的 Microsoft Excel 工作表設為手動更新。

For Each sld In ActivePresentation.Slides

    For Each sh In sld.Shapes

        If sh.Type = msoLinkedOLEObject Then

            If sh.OLEFormat.ProgID = "Excel.Sheet.12" Then

                sh.LinkFormat.AutoUpdate = ppUpdateOptionManual

            End If

        End If

    Next

Next

下列範例會迴圈瀏覽使用中簡報中所有投影片上的所有圖形,並在設定自動更新之前更新連結的 Microsoft Excel 圖表。

For Each sld In ActivePresentation.Slides

    For Each sh In sld.Shapes

        If sh.HasChart Then

            If sh.Chart.ChartData.IsLinked Then

                Call sh.LinkFormat.Update
                sh.LinkFormat.AutoUpdate = ppUpdateOptionAutomatic

            End If

        End If

    Next

Next

方法

名稱
BreakLink
更新

屬性

名稱
Application
AutoUpdate
Parent
SourceFullName

另請參閱

PowerPoint 物件模型參考資料

支援和意見反應

有關於 Office VBA 或這份文件的問題或意見反應嗎? 如需取得支援服務並提供意見反應的相關指導,請參閱 Office VBA 支援與意見反應。