I have a resource (myPoint) defined in XAML as follows:
<Path Name="myPath">
<Path.Resources>
<Point x:Key="myPoint" X="200" Y="200"/>
</Path.Resources>
</Path>
In the OnApplyTemplate override in the corresponding C# code, I use the following to get a reference to this resource.
myPointReference = (Point)myPath.FindResource("myPoint");
Now, whenever I modify the value of myPointReference, let's say,
myPointReference.X = 30;
it doesn't modify the value of the resource myPoint, it only changes the value of myPointReference. How can I make myPointReference an actual reference to my XAML defined resource myPoint so that when I modify the value of myPointReference, I am also modifying the value of myPoint?