Table of contents

PictureFormat.LinkedFileStatus 属性 (发布服务器)PictureFormat.LinkedFileStatus Property (Publisher)

office 365 dev account|上次更新日期: 2018/3/13
2 参与人员

返回一个PbLinkedFileStatus常量,该常量指示链接到指定图片的文件的状态。只读的。Returns a PbLinkedFileStatus constant that indicates the status of the file linked to the specified picture. Read-only.


表达式LinkedFileStatusexpression. LinkedFileStatus

_expression_A 表示PictureFormat对象的变量。_expression_A variable that represents a PictureFormat object.

返回值Return Value



此属性仅应用于链接的图片文件。对于代表嵌入或粘贴图片形状返回"权限被拒绝"。This property only applies to linked picture files. It returns "Permission Denied" for shapes representing embedded or pasted pictures.

使用下列属性之一可确定一个形状是否代表链接图片:Use either of the following properties to determine whether a shape represents a linked picture:

LinkedFileStatus属性值可以是在 Microsoft 发布服务器类型库声明的PbLinkedFileStatus常量之一。The LinkedFileStatus property value can be one of the PbLinkedFileStatus constants declared in the Microsoft Publisher type library.


以下示例生成在当前出版物中找不到链接文件的链接图片列表。The following example generates a list of the linked pictures in the active publication for which the linked files cannot be found.

Dim pgLoop As Page 
Dim shpLoop As Shape 

For Each pgLoop In ActiveDocument.Pages 
 For Each shpLoop In pgLoop.Shapes 
 If shpLoop.Type = pbLinkedPicture Then 

 With shpLoop.PictureFormat 
 If .LinkedFileStatus = pbLinkedFileMissing Then 
 Debug.Print .Filename 
 End If 
 End With 

 End If 
 Next shpLoop 
Next pgLoop 
© 2018 Microsoft