DocumentBase.Route 方法

使用文档的当前传送名单传送文档。

命名空间:  Microsoft.Office.Tools.Word
程序集:  Microsoft.Office.Tools.Word.v4.0.Utilities(在 Microsoft.Office.Tools.Word.v4.0.Utilities.dll 中)

语法

声明
Public Sub Route
public void Route()

备注

如果文档没有传送名单,则将引发异常。 使用 HasRoutingSlip 属性确定是否向文档附加了传送名单。 传送文档会将 Routed 属性设置为 true。

示例

下面的代码示例为文档创建一个传送名单并填写主题和收件人。 该代码然后将文档传送给收件人。 若要使用此示例,请从文档级项目内的 ThisDocument 类中运行此示例。

Private Sub DocumentRoute()
    Me.HasRoutingSlip = True
    Me.RoutingSlip.Subject = "Your feedback is needed."
    Me.RoutingSlip.AddRecipient("someone@example.com")
    Me.Route()
End Sub 
private void DocumentRoute()
{
    this.HasRoutingSlip = true;
    this.RoutingSlip.Subject = "Your feedback is needed.";
    this.RoutingSlip.AddRecipient("someone@example.com");
    this.Route();
}

.NET Framework 安全性

请参见

参考

DocumentBase 类

Microsoft.Office.Tools.Word 命名空间