Replies: 2 comments 1 reply
-
@hxhgxy You should be able to achieve this by applying your attached property to the style used for the "editing element". When a data grid cell of a So you should define a named |
Beta Was this translation helpful? Give feedback.
-
Thanks. If so, it is easier to use DataGridTemplateColumn, right? I'm using TextBox under DataGridTemplateColumn and set the attached property on TextBox currently. |
Beta Was this translation helpful? Give feedback.
-
I made attach property for TextBox to accept numbers only. How can I apply this to DataGridTextColumn?
Thanks,
` public static bool GetIsOnlyNumber(DependencyObject obj)
{
return (bool)obj.GetValue(IsOnlyNumberProperty);
}
`
Beta Was this translation helpful? Give feedback.
All reactions