This question is locked. New answers and comments are not allowed.
Hi,
I have a code that uses the standard Silverlight DataGrid and does the following:
In run time, it gets a collection of items.
Each item has a 'name' property and a collection of items (dates with appointments data inside).
Using the code itself, I managed to dynamically create one column for the name property and few columns for each item in the dates collection so that it looks as if it's a flat grid.
The first column presents a simple text (the name)
The other columns presents a user control - which is relevant to the specific date and presents a list of appointments.
The implementation included overriding the DataGridColumn class and overriding the GenerateElement function in order to create the user control and bind it to a specific item in the collection using converters.
I'm looking for ways to implement the same thing with the new GridView.
The samples I saw so far were mostly XAML based, and I'm looking for a way to do it by code.
I need to be able to define in runtime - how many columns will be in the grid, which user controls to place inside and perform the binding to a specific item in the collection.
Thanks in advance.
I have a code that uses the standard Silverlight DataGrid and does the following:
In run time, it gets a collection of items.
Each item has a 'name' property and a collection of items (dates with appointments data inside).
Using the code itself, I managed to dynamically create one column for the name property and few columns for each item in the dates collection so that it looks as if it's a flat grid.
The first column presents a simple text (the name)
The other columns presents a user control - which is relevant to the specific date and presents a list of appointments.
The implementation included overriding the DataGridColumn class and overriding the GenerateElement function in order to create the user control and bind it to a specific item in the collection using converters.
I'm looking for ways to implement the same thing with the new GridView.
The samples I saw so far were mostly XAML based, and I'm looking for a way to do it by code.
I need to be able to define in runtime - how many columns will be in the grid, which user controls to place inside and perform the binding to a specific item in the collection.
Thanks in advance.