Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

DocumentEvents2_Event.XMLBeforeDelete Event 

Occurs when a user deletes an XML element from a document.

Namespace: Microsoft.Office.Interop.Word
Assembly: Microsoft.Office.Interop.Word (in microsoft.office.interop.word.dll)

'Usage
WithEvents documentEvents2_Event1 As DocumentEvents2_Event
Function documentEvents2_Event1_XMLBeforeDelete(DeletedRange As Range, _
	OldXMLNode As XMLNode, _
	InUndoRedo As Boolean) As Void
	Handles documentEvents2_Event1.XMLBeforeDelete
End Function

event DocumentEvents2_XMLBeforeDeleteEventHandler XMLBeforeDelete;
 void add_XMLBeforeDelete(DocumentEvents2_XMLBeforeDeleteEventHandler handler);
 void remove_XMLBeforeDelete(DocumentEvents2_XMLBeforeDeleteEventHandler handler);
In JScript, you can handle the events defined by a class, but you cannot define your own.

If more than one element is deleted from the document at the same time (for example, when cutting and pasting XML), the event fires for each element that is deleted.


Development Platforms

Windows XP Home Edition, Windows XP Professional, Windows Server 2003, and Windows 2000

Target Platforms

Community Additions

Show: