6 Answers, 1 is accepted
0
Hello CS,
If you expose a property of your business object , that contains only the date part, you may set this property to the GridViewDataColumn.GroupMemberPath. This way when the user groups by the datetime column , RadGridView will perform the actual grouping on your new property.
Best wishes,
Pavel Pavlov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
If you expose a property of your business object , that contains only the date part, you may set this property to the GridViewDataColumn.GroupMemberPath. This way when the user groups by the datetime column , RadGridView will perform the actual grouping on your new property.
Best wishes,
Pavel Pavlov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
CS
Top achievements
Rank 1
answered on 19 May 2010, 02:27 PM
Thank you Pavel, but exposing a new property of just the date would be quite difficult in my case. I essentially bind the GridView to a pseudo-datatable object that we have created in Silverlight and the columns in the datatable are dynamic. I have a number of datasources that this datatable object could be loaded from and each datasource could contain one or many datetime fields.
Can you think of any other way to do it? Is there a way to specify a converter for each gridviewdatacolumn that can be used to define the value that would be used from each row for grouping purposes? That way I could convert from datetime to just date in the converter?
Thanks,
Craig
Can you think of any other way to do it? Is there a way to specify a converter for each gridviewdatacolumn that can be used to define the value that would be used from each row for grouping purposes? That way I could convert from datetime to just date in the converter?
Thanks,
Craig
0
Hi CS,
Please try to set the GroupMemberPaht to the Nested Date property of your DateTime property.
For Example if your DateTime property is named "MyProperty" the setting should be something like .
GroupMemberPath = "MyProperty.Date".
Kind regards,
Pavel Pavlov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Please try to set the GroupMemberPaht to the Nested Date property of your DateTime property.
For Example if your DateTime property is named "MyProperty" the setting should be something like .
GroupMemberPath = "MyProperty.Date".
Kind regards,
Pavel Pavlov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
CS
Top achievements
Rank 1
answered on 21 May 2010, 02:36 PM
Thanks Pavel, but it does not work for me because the property I am binding to is of type object, not datetime. I tried adding a Convert.ToDateTime expression into the GroupMemberPath, but that did not work either. Is there any way that my situation could be supported in a future version of the GridView?
Craig
Craig
0
Accepted
Hello CS,
I am logging the problem and it will be addressed soon . Meanwhile the only solution would be to store the date in a DateTime property rather than Object.
Sincerely yours,
Pavel Pavlov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
I am logging the problem and it will be addressed soon . Meanwhile the only solution would be to store the date in a DateTime property rather than Object.
Sincerely yours,
Pavel Pavlov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
CS
Top achievements
Rank 1
answered on 25 May 2010, 03:11 PM
Thanks, that's great.