How to define datatemplates for datagrid? -


this basic question, i'm new , relying on google searches, so...

i'm trying put datagrid displays rows of text containing id , multiple languages. i'm basing each row off class "textrow" contains id , collection of languagecell items, each containing language , text (i plan add more later):

    public class textrowclass     {         public string label { get; internal set; }         public dictionary<string, languagecell> textcells { get; internal set; }          public class languagecell         {             public string language { get; internal set; }             public string text { get; internal set; }         }     } 

my question is: how set datagrid display information in languagecell class want? (in case, display text element in cell , using other elements (to added) various other purposes.) i'm sure has defining datatemplate, can't find information it.

thanks!

i found answer question in converting class datatable , using itemssource. in doing so, ran across problem datagrids treat in datatable datarowview, post solved problem:

http://social.msdn.microsoft.com/forums/en/wpf/thread/8b2e94b7-3c44-4642-8acc-851de5285062

likely not best or elegant solution, 1 able find.


Comments

Popular posts from this blog

c# - How to set Z index when using WPF DrawingContext? -

razor - Is this a bug in WebMatrix PageData? -

android - layout with fragment and framelayout replaced by another fragment and framelayout -