Xml Dataset and TreeView

  • Thread starter Thread starter John Underwood
  • Start date Start date
J

John Underwood

Hi.. After I sent that message I realized you can do something like
foreach statement below to get to the children.. .. I'm still curious
how people handle this though..

thanks.. John

foreach(DataRelation myRelation in dataset.Tables[x].ChildRelations)
{}
 
Hi
i don't exactly get what is the problem !!! you do it exactly as you said
, then inside the loop the my realation object will have a new refernce
for a new relation with each iteration , with that refernce have full
access to that refenced relation and you can do all possible operations on
it
foreach(DataRelation myRelation in
dataset.Tables[x].ChildRelations)
{



myrealtion. (some property)
//with the dot you will see all properties and method of the current
relation

// the one that now share refernce with myrealtion

//so you can apply all logic that you want to achieve on that realtion



}
Mohamed Mahfouz
MEA Developer Support Center
ITworx on behalf of Microsoft EMEA GTSC
 
Back
Top