Partilhar via


CodeEvent.Remover Property

Definition

Gets or sets the event listeners.

public:
 property EnvDTE::CodeFunction ^ Remover { EnvDTE::CodeFunction ^ get(); void set(EnvDTE::CodeFunction ^ value); };
public:
 property EnvDTE::CodeFunction ^ Remover { EnvDTE::CodeFunction ^ get(); void set(EnvDTE::CodeFunction ^ value); };
[System.Runtime.InteropServices.DispId(38)]
public EnvDTE.CodeFunction Remover { [System.Runtime.InteropServices.DispId(38)] get; [System.Runtime.InteropServices.DispId(38)] set; }
[<System.Runtime.InteropServices.DispId(38)>]
[<get: System.Runtime.InteropServices.DispId(38)>]
[<set: System.Runtime.InteropServices.DispId(38)>]
member this.Remover : EnvDTE.CodeFunction with get, set
Public Property Remover As CodeFunction

Property Value

The CodeFunction object.

Attributes

Examples

The following example demonstrates how to use the Remover property.

public static void Remover(EnvDTE80.DTE2 dte)  
{  
    TextSelection objTextSel;  
    EnvDTE80.CodeEvent codeEvent;  
    objTextSel = (TextSelection)dte.ActiveDocument.Selection;  
    codeEvent = (EnvDTE80.CodeEvent)objTextSel. _  
      ActivePoint.get_CodeElement(vsCMElement.vsCMElementEvent);  

    MessageBox.Show("\nRemover property: " +  
                    codeEvent.Remover, "Testing CodeEvent");  
}  

Remarks

The CodeFunction object is used to remove event listeners.

Note

The values of code model elements such as classes, structs, functions, attributes, delegates, and so forth can be non-deterministic after making certain kinds of edits, meaning that their values cannot be relied upon to always remain the same.

Applies to