Share via


GetTarget Method

This is a helper method that returns the target object for a delegate. If the delegate was created to proxy a generic delegate, this will correctly return the original object, not the proxy.

Namespace:  Microsoft.Data.Tools.Design.Core.Context
Assembly:  Microsoft.Data.Tools.Design.Core (in Microsoft.Data.Tools.Design.Core.dll)

Syntax

'Declaration
Protected Shared Function GetTarget ( _
    callback As Delegate _
) As Object
'Usage
Dim callback As [Delegate]
Dim returnValue As Object

returnValue = ContextItemCollection.GetTarget(callback)
protected static Object GetTarget(
    Delegate callback
)
protected:
static Object^ GetTarget(
    Delegate^ callback
)
static member GetTarget : 
        callback:Delegate -> Object 
protected static function GetTarget(
    callback : Delegate
) : Object

Parameters

Return Value

Type: System..::..Object
The target object of the callback.

Exceptions

Exception Condition
ArgumentNullException

if callback is null.

See Also

Reference

ContextItemCollection Class

Microsoft.Data.Tools.Design.Core.Context Namespace