title: Should binding to Path.Data property work?
body: <p><strong>EDIT: Note! This turned out to be a typo in my code</strong></p>
  
  <p><a href="http://msdn.microsoft.com/en-us/library/system.windows.shapes.path.data.aspx" rel="nofollow">According to msdn</a> , Path.Data appears to be bindable. But I am not sure how to read the Depenedency Property Information part of the msdn page. Is AffectsRender and AffectsMeasure be enough for my use? </p>
  
  <p>If I use x:Name to directly assign it, the geometry appears </p>
  
  <pre><code>var curve = new GeometryGroup();
  curve.Children.Add(new LineGeometry(new Point(0, 0), new Point(20, 20)));
  curve.Children.Add(new LineGeometry(new Point(0, 20), new Point(20, 0)));
  CurveGraph.Data = curve;
  </code></pre>
  
  <p>This works fine. Draws a nice "X".</p>
  
  <p>However, if I have a dependency property of type GeometryGroup in the ViewModel</p>
  
  <pre><code>var curve = new GeometryGroup();
  curve.Children.Add(new LineGeometry(new Point(0, 0), new Point(20, 20)));
  curve.Children.Add(new LineGeometry(new Point(0, 20), new Point(20, 0)));
  GeometryData= curve;
  </code></pre>
  
  <p>dp :</p>
  
  <pre><code>public GeometryGroup GeometryData
      {
          get { return (GeometryGroup)GetValue(GeometryDataProperty); }
          set { SetValue(GeometryDataProperty, value); }
      }
  
      public static readonly DependencyProperty GeometryDataProperty =  DependencyProperty.Register("GeometryDataProperty", typeof(GeometryGroup), typeof(MiniTrendVm), new UIPropertyMetadata(new GeometryGroup()));
  </code></pre>
  
  <p>...then it didn't work. Nothing happens. No "X".</p>
  
  <p>xaml : </p>
  
  <pre><code>&lt;Path Data="{Binding GeometryData}" x:Name="CurveGraph" Stroke = "{Binding StrokeColor}" StrokeThickness = "2" Grid.RowSpan="4"/&gt; 
  </code></pre>
  
  <p>Should this work? Have I fat fingered something? Or can't the Data property be set this way? The brush was databound in both cases, so I know that the datacontext is correctly set.</p>