Bookmark.ItalicBi Property

Definition

Gets or sets a value that indicates whether the text in the Bookmark control is formatted as italic.

public:
 property int ItalicBi { int get(); void set(int value); };
public int ItalicBi { get; set; }
member this.ItalicBi : int with get, set
Public Property ItalicBi As Integer

Property Value

0 if none of the text in the Bookmark control text is italic; 1 if all of the text in the Bookmark control is italic; wdUndefined (999999) if part of the text in a Bookmark control is italic.

Examples

The following code example adds a Bookmark control to the document and then applies formatting to the bookmark based on the LanguageID of the text within the bookmark.

This example is for a document-level customization.

private void BookmarkBiDi()
{
    Microsoft.Office.Tools.Word.Bookmark bookmark1 =
        this.Controls.AddBookmark(this.Paragraphs[1].Range,
        "bookmark1");
    
    int WordTrue = 1;
    if (bookmark1.LanguageID == Word.WdLanguageID.wdArabic || 
        bookmark1.LanguageID == Word.WdLanguageID.wdHebrew)
    {
        bookmark1.BoldBi = WordTrue;
        bookmark1.ItalicBi = WordTrue;
    }
    else
    {
        bookmark1.Bold = WordTrue;
        bookmark1.Italic = WordTrue;
    }
}
Private Sub BookmarkBiDi()
    Dim Bookmark1 As Microsoft.Office.Tools.Word.Bookmark = _
        Me.Controls.AddBookmark(Me.Paragraphs(1).Range, "Bookmark1")

    If Bookmark1.LanguageID = Word.WdLanguageID.wdArabic OrElse _
        Bookmark1.LanguageID = Word.WdLanguageID.wdHebrew Then
        Bookmark1.BoldBi = True
        Bookmark1.ItalicBi = True
    Else
        Bookmark1.Bold = True
        Bookmark1.Italic = True
    End If
End Sub

Remarks

The values this property can be set to are 0, 1, or wdToggle.

The ItalicBi property applies to text in right-to-left languages.

Applies to