I know that this might seems very strange but I have the need to automatically put in the tag the name of a graphic Element e.g.
var tbkMain = new TextBlock(){Foreground = ...,..., Tag = ??? } <----here I wish automatically Tag= "TbkMain"
var grdSmall = new TextBlock(){Foreground = ...,..., Tag = ??? } <----here I wish automatically Tag= "grdSmall"
also something done afterwards like
tbkMain.Tag = ???;
or (and even better):
foreach(var element in grdMain.Children)
element.Tag = ???
Thanks
I have to admit I do not even know if that is possible or where to start from. Thanks