DocumentBase.AddToFavorites Method

Creates a shortcut to the document and adds it to the Favorites folder.

Namespace:  Microsoft.Office.Tools.Word
Assembly:  Microsoft.Office.Tools.Word.v4.0.Utilities (in Microsoft.Office.Tools.Word.v4.0.Utilities.dll)

Syntax

'Declaration
Public Sub AddToFavorites
public void AddToFavorites()

Examples

The following code example adds the current document to the Favorites folder. To use this example, run it from the ThisDocument class in a document-level project.

Private Sub DocumentAddToFavorites()
    Me.AddToFavorites()
End Sub
private void DocumentAddToFavorites()
{
    this.AddToFavorites();
}

.NET Framework Security

See Also

Reference

DocumentBase Class

Microsoft.Office.Tools.Word Namespace