I having trouble to manipulate CeLLs content in Silverlight Grids... I can get my DataGrid, the Columns but not the Cell value.
How can I get the first Cell wich is an Image in a Button for every row?? I can only achieve my goal by even开发者_运维知识库ts like the button_click but not in regulare code behind.
thanks for help
You can use DataGrid.SelectedItem
property and cast record to your desired object.
Customer c = GrdCustomers.SelectedItem as Customer;
if (c != null)
{
string customerId = c.CustomerID;
}
assuming you have your datasource as Customer.
精彩评论