title: Two way binding requires Path or XPath, DataGrid binding
body: <p>I have a DataGrid that is to be filled in by the user, XAML:</p>
  
  <pre><code>&lt;DataGrid ItemsSource="{Binding Path=Input.InloopAangepast, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"&gt;
      &lt;DataGrid.Columns&gt;
          &lt;DataGridTextColumn Binding="{Binding Path=TypeOppervlak}"/&gt;
          &lt;DataGridTextColumn Binding="{Binding Path=TypeAfstroming}"/&gt;
          &lt;DataGridTextColumn Binding="{Binding Path=Parameters[0].Double}"/&gt;
          &lt;DataGridTextColumn Binding="{Binding Path=Parameters[1].Double}"/&gt;
          &lt;DataGridTextColumn Binding="{Binding Path=Parameters[2].Double}"/&gt;
          &lt;DataGridTextColumn Binding="{Binding Path=Parameters[3].Double}"/&gt;
          &lt;DataGridTextColumn Binding="{Binding Path=Parameters[4].Double}"/&gt;
          &lt;DataGridTextColumn Binding="{Binding Path=Parameters[5].Double}"/&gt;
          &lt;DataGridTextColumn Binding="{Binding Path=Parameters[6].Double}"/&gt;
      &lt;/DataGrid.Columns&gt;
  &lt;/DataGrid&gt;
  </code></pre>
  
  <p>ViewModel:</p>
  
  <pre><code>InloopAangepast = new ObservableCollection&lt;Inloop&gt;();
  </code></pre>
  
  <p>And:  </p>
  
  <pre><code>public class Inloop : INotifyPropertyChanged
  {
      public Inloop()
      {
          Parameters =  new ObservableCollection&lt;InloopParameter&gt;();
      }
  
      private string _typeOppervlak;
      private string _typeAfstroming;
      private string _omschrijving;
      public ObservableCollection&lt;InloopParameter&gt; _parameters;
  
      public string TypeOppervlak
      {
          get
          {
              return _typeOppervlak;
          }
          set
          {
              _typeOppervlak = value;
              if (PropertyChanged != null)
              {
                  this.PropertyChanged(this, new PropertyChangedEventArgs("TypeOppervlak"));
              }
          }
      }
  
      public string TypeAfstroming
      {
          get
          {
              return _typeAfstroming;
          }
          set
          {
              _typeAfstroming = value;
              if (PropertyChanged != null)
              {
                  this.PropertyChanged(this, new PropertyChangedEventArgs("TypeAfstroming"));
              }
          }
      }
  
      public string Omschrijving
      {
          get
          {
              return _omschrijving;
          }
          set
          {
              _omschrijving = value;
              if (PropertyChanged != null)
              {
                  this.PropertyChanged(this, new PropertyChangedEventArgs("Omschrijving"));
              }
          }
      }
  
      public ObservableCollection&lt;InloopParameter&gt; Parameters
      {
          get
          {
              return _parameters;
          }
          set
          {
              _parameters = value;
              if (PropertyChanged != null)
              {
                  this.PropertyChanged(this, new PropertyChangedEventArgs("Parameters"));
              }
          }
      }
  
      public event PropertyChangedEventHandler PropertyChanged;
  }
  
  public class InloopParameter : INotifyPropertyChanged
  {
      public InloopParameter()
      {
  
      }
  
      private string _naam;
      private string _string;
      private double? _double;
  
      public string Naam
      {
          get
          {
              return _naam;
          }
          set
          {
              _naam = value;
              if (PropertyChanged != null)
              {
                  this.PropertyChanged(this, new PropertyChangedEventArgs("Naam"));
              }
          }
      }
  
      public string String
      {
          get
          {
              return _string;
          }
          set
          {
              _string = value;
              if (PropertyChanged != null)
              {
                  this.PropertyChanged(this, new PropertyChangedEventArgs("String"));
              }
          }
      }
  
      public double? Double
      {
          get
          {
              return _double;
          }
          set
          {
              _double = value;
              if (PropertyChanged != null)
              {
                  this.PropertyChanged(this, new PropertyChangedEventArgs("Double"));
              }
          }
      }
  
      public event PropertyChangedEventHandler PropertyChanged;
  }
  </code></pre>
  
  <p>I can enter the first two fields (TypeOppervlak and TypeAfstroming) fine, but when I enter one of the other fields I get an error "Two way binding requires Path or XPath". What am I doing wrong?</p>