wpf - Perform actions on DataTemplate's datas when they are completely loaded? -
i have itemscontrols in datatemplate "grid".
i dynamically bind values itemscontrol itemsource.
i donot know how itemsource's list count be!.
i want perform actions on complete set of data, after datatemplate's data bounded. (i mean grids data, loaded).
may know how find it?
ex:
<itemssource itemsource={bindiing listofdata}> <datatemplate> <grid> <textblock text={binding name} grid.coulm=0/> <textblock text={binding age} grid.coulm=1/> <textblock text={binding address} grid.coulm=2/> </grid> </datatemplate> </itemsource>
public list < persons> listofdata;
class persons { public string name; public string age; public string address; }
now consider listofdata having 50 objects of type persons. may change @ runtime.
now want perform operations on list of 50 person objects, after gets loaded itemscontrol. (not on individual person object).
if used loaded event grid, fired 50 times each person object(while loading grid).
i want fire event when list loaded.
is there way it??
thanks in advance.
if want check number of element, may check when binding dynamically or if want perform operation on grid rows, may write in grid_loaded event . rows there.
Comments
Post a Comment