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!

RichControl.Invoke

[To be supplied.]

Overload List

Executes the given delegate on the thread that owns this Control's underlying window handle. It is an error to call this on the same thread that the control belongs to. If the control's handle doesn't exist yet, this will follow up the control's parent chain until it finds a control or form that does have a window handle. If no appropriate handle can be found, invoke will throw an exception. Exceptions that are raised during the call will be propapgated back to the caller. There are five functions on a control that are safe to call from any thread: GetInvokeRequired, Invoke, BeginInvoke, EndInvoke and CreateGraphics. For all other metohd calls, you should use one of the invoke methods to marshal the call to the control's thread.

[Visual Basic] Overloads Public Function Invoke(Delegate) As Object
[C#] public object Invoke(Delegate);
[C++] public: Object* Invoke(Delegate*);
[JScript] public function Invoke(Delegate) : Object;

Executes the given delegate on the thread that owns this Control's underlying window handle. It is an error to call this on the same thread that the control belongs to. If the control's handle doesn't exist yet, this will follow up the control's parent chain until it finds a control or form that does have a window handle. If no appropriate handle can be found, invoke will throw an exception. Exceptions that are raised during the call will be propapgated back to the caller. There are five functions on a control that are safe to call from any thread: GetInvokeRequired, Invoke, BeginInvoke, EndInvoke and CreateGraphics. For all other metohd calls, you should use one of the invoke methods to marshal the call to the control's thread.

[Visual Basic] Overloads Overridable Public Function Invoke(Delegate, Object()) As Object
[C#] public virtual object Invoke(Delegate, Object[]);
[C++] public: virtual Object* Invoke(Delegate*, Object[]);
[JScript] public function Invoke(Delegate, Object[]) : Object;

See Also

RichControl Class | RichControl Members | System.WinForms Namespace