Bookmark.LanguageIDOther, propriété

Obtient ou définit la langue du contrôle Bookmark.

Espace de noms :  Microsoft.Office.Tools.Word
Assembly :  Microsoft.Office.Tools.Word (dans Microsoft.Office.Tools.Word.dll)

Syntaxe

'Déclaration
Property LanguageIDOther As WdLanguageID
WdLanguageID LanguageIDOther { get; set; }

Valeur de propriété

Type : Microsoft.Office.Interop.Word.WdLanguageID
Une des valeurs de WdLanguageID.

Notes

C'est la façon que nous recommandons pour retourner ou définir la langue d'un texte de langue latine d'un document créé dans une version de Microsoft Office Word utilisant une langue écrite de droite à gauche.

Exemples

L'exemple de code suivant ajoute un contrôle Bookmark au premier paragraphe et donne à la propriété LanguageIDOther la valeur Français.

Cet exemple illustre une personnalisation au niveau du document.

Private Sub BookmarkLanguageIDOther()
    Dim Bookmark1 As Microsoft.Office.Tools.Word.Bookmark = _
        Me.Controls.AddBookmark(Me.Paragraphs(1).Range, "Bookmark1")
    Bookmark1.LanguageIDOther = Word.WdLanguageID.wdFrench
    MessageBox.Show("Bookmark1's LanguageID is set to " & _
        Bookmark1.LanguageID.ToString)

End Sub
private void BookmarkLanguageIDOther()
{
    Microsoft.Office.Tools.Word.Bookmark bookmark1 =
        this.Controls.AddBookmark(this.Paragraphs[1].Range,
        "bookmark1");

    bookmark1.LanguageIDOther = Word.WdLanguageID.wdFrench;
    MessageBox.Show("Bookmark1's LanguageID is set to " +
        bookmark1.LanguageID.ToString());
}

Sécurité .NET Framework

Voir aussi

Référence

Bookmark Interface

Microsoft.Office.Tools.Word, espace de noms