method Edit.DeleteKeyword (Keyword as String)
Deletes a keyword from keywords collection.

TypeDescription
Keyword as String A string expression that defines the keyword being deleted. The Keyword parameter must not include HTML tags.

Use the DeleteKeyword method to delete a particular keyword from the keywords collection. The DeleteKeyword method has effect only if the control's EditType property is exSensitive. Use the ClearKeywords method to clear all keywords.  Use the Refresh method  to let control reflects changes in the visible area.

The following VB sample adds a keyword when the form is loaded:

Private Sub Form_Load()
    With Edit1
        .AddKeyword "<b>public</b>", "The public keyword's tooltip."
        .Refresh
    End With
End Sub

The following VB sample removes a keyword when the user presses a button:

Private Sub Command1_Click()
    With Edit1
        .DeleteKeyword "public"
        .Refresh
    End With
End Sub

Important to note is that the "public" keyword doesn't include the HTML tags, when DeleteKeyword method is called.

The following C++ sample adds a keyword when the form is loaded:

COleVariant vtMissing; vtMissing.vt = VT_ERROR;
m_edit.AddKeyword("<b>public</b>", COleVariant( "The public keyword's tooltip." ), vtMissing, vtMissing);
m_edit.Refresh();

The following C++ sample removes a keyword when the user presses a button:

void OnButton1() 
{
	m_edit.DeleteKeyword( "public" );
	m_edit.Refresh();
}

The following VB.NET sample adds a keyword when the form is loaded:

With AxEdit1
    .AddKeyword("<b>public</b>", "The public keyword's tooltip.", Nothing, Nothing)
    .CtlRefresh()
End With

The following VB.NET sample removes a keyword when the user presses a button:

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
	With AxEdit1
		.DeleteKeyword("public")
		.CtlRefresh()
	End With
End Sub

The following C# sample adds a keyword when the form is loaded:

axEdit1.AddKeyword("<b>public</b>", "The public keyword's tooltip.", null, null);
axEdit1.CtlRefresh();

The following C# sample removes a keyword when the user presses a button:

private void button1_Click(object sender, EventArgs e)
{
	axEdit1.DeleteKeyword("public");
	axEdit1.CtlRefresh();
}

The following VFP sample adds a keyword when the form is loaded:

With thisform.Edit1.Object
	.AddKeyword("<b>public</b>", "The public keyword's tooltip.")
	.Refresh()
EndWith

The following VFP sample removes a keyword when the user presses a button:

with thisform.Edit1.Object
	.DeleteKeyword("public")
	.Refresh()
endwith