Storyboard.TargetProperty Attached Property
Gets or sets the name of the property that should be animated.
Assembly: System.Windows (in System.Windows.dll)
XMLNS for XAML: Not mapped to an xmlns.
Dependency property identifier field: TargetPropertyProperty
The value of must refer to an existing property of the element that is referenced by Storyboard.TargetName. For more information, see the "Creating a Storyboard" section of Animations, motion, and output for Windows Phone.
supports the concept of indirect property targeting, and uses a property path syntax to specify indirect targeting. Indirect property targeting is necessary when the type of the property that is being animated is itself an object, but the actual animated value is a property of that object instead of the object type itself. This is particularly necessary when markup cannot provide a name for targeting the sub-object, perhaps because it was specified originally in XAML attribute form instead of as a XAML object element. For example, to animate the Fill of a Rectangle using a linear interpolation of a SolidColorBrush, you would specify a ColorAnimation and give it a value of "(Rectangle.Fill).Color".
Another scenario for using property paths is applying an animation to objects that are added to a collection at run time. In this case, you might name the object that holds the collection and then use the property path syntax to iterate to a specific index. In this way, you are able to target an animation to an object that has no name but that exists as a sub-property of a named object.
Attempting to set on a running animation will cause a run-time error. However, you can retarget existing animations that are stopped or not yet running. If you retarget animations, you usually want to use a target that is the same type, or that shares the property because of a base object definition. If you retarget an animation by changing Storyboard.TargetName, and references an unsupported property, you will get a run-time error.
The property you target must use the type of the animation that you are applying. For example, if you want to animate properties of an EllipseGeometry, you would use a DoubleAnimation (or DoubleAnimationUsingKeyFrames) to animate RadiusX or RadiusY, and a PointAnimation (or PointAnimationUsingKeyFrames) to animate Center. A mismatch of types will cause a parser error. The types must be exact matches; there is no implicit type conversion for animated properties. For example, you cannot animate a target of "(Canvas.ZIndex)" with a DoubleAnimation because Canvas.ZIndex takes an integer, not a double.
For the propertyName syntax that involves collections, the collection cannot be the last item in the property chain, because object types contained in the collections cannot be directly animated with the Double, Color, and Point animation types. You must terminate the property chain with a specific property of the object that comes from an index in a collection.