Saturday, September 15, 2012

Datagrid value does not change

Datagrid value does not change

I have a TextBox in CellEditingTemplate in datagird. When I change its value but it is not reflected to new value.

<TextBox Text="{Binding Path=Firstname}" Grid.Column="1" Width="80"  ></TextBox> 

How can I do this?

Answers & Comments...

Answer: 1

You have to use Mode=TwoWay and also use INotifyPropertyChanged with Firstname.

<TextBox Text="{Binding Path=Firstname,Mode=TwoWay}" Grid.Column="1" Width="80"/> 

Thanks.

by : Hiteshhttp://stackoverflow.com/users/1309558




No comments:

Post a Comment

Send us your comment related to the topic mentioned on the blog