Table of contents
TOC
折叠目录
展开目录

ServerPolicy 对象 (办公室)ServerPolicy Object (Office)

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

代表指定的文档类型存储在运行 Microsoft Office SharePoint 服务器的服务器上的策略。Represents a policy specified for a document type stored on a server running Microsoft Office SharePoint Server.

注解Remarks

ServerPolicy对象由单个PolicyItem对象代表活动文档的单独的策略定义。The ServerPolicy object is composed of individual PolicyItem objects representing the individual policy definitions for the active document.

示例Example

以下示例列出了活动文档所有策略项目的名称和说明。The following example lists the name and description of all of the policy items for the active document.

Sub ListPolicyItems() 
Dim objSrvPolicy As ServerPolicy 
Dim objPolicyItem As PolicyItem 
Dim strPolicyItemList As String 

Set objSrvPolicy = ActiveDocument.ServerPolicy 

For Each objPolicyItem In objSrvPolicy 
 strPolicyItemList = "Policy Item " & objPolicyItem.Name & " - " & _ 
 objPolicyItem.Description & vbCrLf 
Next 
MsgBox (strPolicyItemList) 

End Sub 

属性Properties

名称Name
ApplicationApplication
BlockPreviewBlockPreview
CountCount
CreatorCreator
说明Description
IdId
ItemItem
NameName
ParentParent
语句Statement

另请参阅See also

其他资源Other resources

对象模型引用Object Model Reference

© 2018 Microsoft