Export (0) Print
Expand All
Expand Minimize

ResolveEventHandler Delegate

Represents the method that handles the TypeResolve, ResourceResolve, and AssemblyResolve events of an AppDomain.

[Visual Basic]
<Serializable>
Public Delegate Function Sub ResolveEventHandler( _
   ByVal sender As Object, _
   ByVal args As ResolveEventArgs _
) As Assembly
[C#]
[Serializable]
public delegate Assembly ResolveEventHandler(
   object sender,
   ResolveEventArgs args
);
[C++]
[Serializable]
public __gc __delegate Assembly* ResolveEventHandler(
   Object* sender,
   ResolveEventArgs* args
);

[JScript] In JScript, you can use the delegates in the .NET Framework, but you cannot define your own.

Parameters [Visual Basic, C#, C++]

The declaration of your event handler must have the same parameters as the ResolveEventHandler delegate declaration.

sender
The source of the event.
args
A ResolveEventArgs that contains the event data.

Return Value

The Assembly that resolves the type, assembly, or resource.

Remarks

If the runtime class loader cannot resolve a reference to an assembly, type, or resource, then the corresponding events are raised to give the callback a chance to tell the runtime which assembly the referenced assembly, type, or resource is in. It is the responsibility of the ResolveEventHandler to return the assembly that resolves the type, assembly, or resource.

Every derived class of Delegate and MulticastDelegate has a constructor and an Invoke method. See the Managed Extensions for C++ code example in the description for the Delegate class.

Requirements

Namespace: System

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

Assembly: Mscorlib (in Mscorlib.dll)

See Also

System Namespace

Show:
© 2014 Microsoft