c# - Indexing through an Object -
so have datagrid. when row doubleclicked value passed mvvm.
list implementation:
private list<object> _allqueries { get; set; } public list<object> allqueries { { return _allqueries; } set { _allqueries = value; this.notifyofpropertychange(() => allqueries); } }
datagrid implementation:
<telerik:radgridview selecteditem="{binding selecteditem}" itemssource="{binding allqueries, mode=twoway, updatesourcetrigger=propertychanged}" autogeneratecolumns="true">
implementation of selecteditem
public object selecteditem { get; set; }
when put breakpoint selecteditem used it's working perfectly, values being brought. question how interact columns
or properties
using (var ctx = db.get()) = ctx.interactions.find(selecteditem2);
examples of selecteditem be:
id = 200 date = 4/24/2014 name = "billy bob"
is there way index through properties of object selecteditem[0] give me id number.
for generic object coming back, you'd want to try reflection see properties there, grab value of ones want.
edit: misunderstood question.
Comments
Post a Comment