Если я создаю привязку к свойству IsReadOnly
объекта DataGridTextColumn
, он не актуализируется. Если я установил его с помощью разметки, он будет работать.
<DataGridTextColumn IsReadOnly="{Binding IsReferenceInactive}"/> <!-- NOP -->
<DataGridTextColumn IsReadOnly="True"/> <!-- Works as expected, cell is r/o -->
Свойство IsReferenceInactive
является DP и отлично работает (для целей тестирования я привязал его к флажку, который работал)
Является ли это известным ограничением?
Обновление
Uups, кроме того, что я написал, в окне вывода есть сообщение:
System.Windows.Data Error: 2 : Cannot find governing FrameworkElement or FrameworkContentElement for target element. BindingExpression:Path=IsReferenceInactive; DataItem=null; target element is 'DataGridTextColumn' (HashCode=23836176); target property is 'IsReadOnly' (type 'Boolean')
Кажется, это одно: