Hi, someone can help me please. I've a XamDataGrid so i want to get data when i select row. I don't know how to proceed. Anyway the method, for example show the cols result with a MessageBox. Thanks for advance.
Hi,
Thank you for your post. I have been looking into your requirement and my suggestion is to handle the ‘RecordActivated’ event of the XamDataGrid and access the data item like e.g.:
private void xamDataGrid1_RecordActivated(object sender, Infragistics.Windows.DataPresenter.Events.RecordActivatedEventArgs e)
{
var dataItem = (e.Record as DataRecord).DataItem;
}
Let me know, if you need any further assistance on this matter.
I've problem with "DataRecord" (could not be found) ... ?
And the second, i want to get the value cols for e.g. in the first row that i select i want to get the name column. Thanks
Hi Skatox,
Thank you for reply. I have been looking into your requirement and the easiest way to achieve this functionality is casting the DataItem to the underlying type like e.g.:
var dataItem = (e.Record as DataRecord).DataItem as Worker;
MessageBox.Show("Person Name: " + dataItem.Name);
I am attaching a sample application(DataGridFunc.zip) that shows it.
i see it. thx....
Thank you for your replies. Let me know, if you need any further assistance on this matter.
THX FOR ALL, IT'S SOLVED. THANKS :)