ServiceManager.RemoveCallback(Delegate, Delegate) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
A helper method that performs a Delegate.Remove
operation, and unwraps delegates that are proxies to generic callbacks. You should use this method in your Unsubscribe implementations.
protected:
static Delegate ^ RemoveCallback(Delegate ^ existing, Delegate ^ toRemove);
protected static Delegate RemoveCallback (Delegate existing, Delegate toRemove);
static member RemoveCallback : Delegate * Delegate -> Delegate
Protected Shared Function RemoveCallback (existing As Delegate, toRemove As Delegate) As Delegate
Parameters
- existing
- Delegate
The existing delegate to remove the callback from.
- toRemove
- Delegate
The callback to remove.
Returns
Returns Delegate, which is a new value to assign to the existing delegate.
Applies to
Collaborate with us on GitHub
The source for this content can be found on GitHub, where you can also create and review issues and pull requests. For more information, see our contributor guide.