Action.Click Event

Occurs when the action in the smart tag menu is clicked.

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

event ActionClickEventHandler Click

For more information about handling events, see Consuming Events.

The following code example demonstrates a handler for the Click event. The event handler displays the start and end position of the recognized smart tag term. This code example is part of a larger example provided for Action.

void displayAddress_Click(object sender,
    Microsoft.Office.Tools.Word.ActionEventArgs e)
    int termStart = e.Range.Start;
    int termEnd = e.Range.End;
    System.Windows.Forms.MessageBox.Show("The recognized text '" + e.Text +
        "' begins at position " + termStart.ToString() +
        " and ends at position " + termEnd.ToString());

Community Additions