Share via


TargetedTriggerAction Generic Class

Represents an action that can be targeted to affect an object other than its AssociatedObject.

Namespace: System.Windows.Interactivity
Assembly: System.Windows.Interactivity (in system.windows.interactivity.dll)

Syntax

'Declaration
Public MustInherit Class TargetedTriggerAction(Of T)
    Inherits TargetedTriggerAction
'Usage
Dim instance As TargetedTriggerAction(Of T)
public abstract class TargetedTriggerAction<T> : TargetedTriggerAction
generic<typename T>
public ref class TargetedTriggerAction abstract : public TargetedTriggerAction

Remarks

TargetedTriggerAction extends TriggerAction to add knowledge of another element than the one it is attached to. This allows a user to invoke the action on an element other than the one it is attached to in response to a trigger firing. Override OnTargetChanged to hook or unhook handlers on the target element, and OnAttached/OnDetaching for the associated element. The type of the Target element can be constrained by the generic type parameter. If you need control over the type of the AssociatedObject, set a TypeConstraintAttribute on your derived type.

Inheritance Hierarchy

System.Object
   System.Windows.Threading.DispatcherObject
     System.Windows.DependencyObject
       System.Windows.Freezable
         System.Windows.Media.Animation.Animatable
           System.Windows.Interactivity.TriggerAction
             System.Windows.Interactivity.TargetedTriggerAction
              System.Windows.Interactivity.TargetedTriggerAction
                 Microsoft.Expression.Interactivity.Core.ChangePropertyAction
                 Microsoft.Expression.Interactivity.Core.GoToStateAction
                 Microsoft.Expression.Interactivity.Core.RemoveElementAction

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also

Reference

TargetedTriggerAction Members
System.Windows.Interactivity Namespace