WindowObserverAddCallbackFor Method DW.WPFToolkit Documentation
Registers a calback to be invoked when the specific WinAPI message appears in the observed window.

Namespace: DW.WPFToolkit.Helpers
Assembly: DW.WPFToolkit (in DW.WPFToolkit.dll) Version: 5.6.0.0
Syntax

C#
public void AddCallbackFor(
	Nullable<int> messageId,
	Action<NotifyEventArgs> callback
)

Parameters

messageId
Type: SystemNullableInt32
The WinAPI message to listen for. If its null all WinAPI messages will be forwarded to the callback.
callback
Type: SystemActionNotifyEventArgs
The callback to be invoked when the specific WinAPI message appears in the observed window.
Exceptions

ExceptionCondition
ArgumentNullExceptioncallback is null.
Remarks

The callback is not registered as a WeakReference, consider using RemoveCallback(ActionNotifyEventArgs) to remove a callback if its not needed anymore.
See Also

Reference