NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

WaitCallback Delegate

This class is a Delegate which defines the callback method for threadpool user work items. That method must match this delegate.

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

[Visual Basic]
Public Delegate Sub WaitCallback( _
   ByVal state As Object _
)
[C#]
public delegate void WaitCallback(
   object state
);
[C++]
public __gc __delegate void WaitCallback(
   Object* state
);

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

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

The declaration of your event-handling method must have the same parameters as the WaitCallback delegate declaration.

state
The object that is passed to the delegate.

Remarks

See the managed C++ code example specified in the description for the Delegate.

Requirements

Namespace: System.Threading

Assembly: mscorlib.dll

See Also

System.Threading Namespace | ThreadPool