interface ISynchronizeInvoke
in global :: System . ComponentModel
Provides a way to synchronously or asynchronously execute a delegate.
public IAsyncResult BeginInvoke( Delegate method, object[] args )
Asynchronously executes the delegate on the thread that created this object.
methodA to a method that takes parameters of the same number and type that are contained in .argsAn array of type to pass as arguments to the given method. This can be if no arguments are needed.- Returns An interface that represents the asynchronous operation started by calling this method.
public object EndInvoke( IAsyncResult result )
Waits until the process started by calling completes, and then returns the value generated by the process.
resultAn interface that represents the asynchronous operation started by calling .- Returns An that represents the return value generated by the asynchronous operation.
public object Invoke( Delegate method, object[] args )
Synchronously executes the delegate on the thread that created this object and marshals the call to the creating thread.
methodA that contains a method to call, in the context of the thread for the control.argsAn array of type that represents the arguments to pass to the given method. This can be if no arguments are needed.- Returns An that represents the return value from the delegate being invoked, or if the delegate has no return value.
public bool InvokeRequired { get; }
Gets a value indicating whether the caller must call when calling an object that implements this interface.
- Returns if the caller must call ; otherwise, .