WPF Datagrid + MVVM + Header Change by ViewModel
with autogeneratecolumns true.
I have two table entities in a Dbcontext Model. Table2 contains all configuration of column for e.g Header Fieldname, Header Description, Color, Font e.t.c
I am populating table1 in wpf datagrid through viewmodel. I want to replace the header names with the header description of table2 through MVVM
Table1:
(Default WPF Datagrid)
SrNo Col1 Col2
Table2:
FieldName Description
SrNo Serial No
Col1 Name
Col2 Age
My datagrid should be
Serial No Col1 Col2
My table1 and table2 are dynamic and autogenerate columns must be true.