xaml - Traversing elements of Stackpanel -


i new c#/xaml development , have started creating basic windows phone 8 application. want elements (controls) added in stackpanel child stackpanel using stackpanel.children.add(name_of_the_control). want elements or controls added in stackpanel not know how it. have searched on net not helpful link.

please me process of how achieve it.

you can access controls added stackpanel it's children property, example :

foreach(var control in stackpanel.children) {     //here can each element of stackpanel in control variable     //further example :     if(control radiobutton)     {         var radio = (radiobutton)control;         //do radiobutton     }     else if(control textblock)     {         var textblok = (textblock)control;         //do textblock     }     //add other possible type of control want manipulate } 

Comments

Popular posts from this blog

php - SPIP: From Tag directly to an article -

jquery - isAjaxRequest always return false -

ruby on rails - In a controller spec, how to find a specific tag in the generated view? -