Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/wpf/14.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# windows 8 metro应用程序中的分组CollectionViewSource_C#_Wpf_Windows 8_Microsoft Metro_Winrt Xaml - Fatal编程技术网

C# windows 8 metro应用程序中的分组CollectionViewSource

C# windows 8 metro应用程序中的分组CollectionViewSource,c#,wpf,windows-8,microsoft-metro,winrt-xaml,C#,Wpf,Windows 8,Microsoft Metro,Winrt Xaml,我的metro应用程序的XAML代码中是否可以将CollectionViewSource元素指定为 <CollectionViewSource x:Name="groupedAppointments" IsSourceGrouped="True" d:Source="{Binding Appointments, Source={d:DesignInstance Type=dataModel:SampleDa

我的metro应用程序的XAML代码中是否可以将CollectionViewSource元素指定为

<CollectionViewSource x:Name="groupedAppointments" IsSourceGrouped="True"
                      d:Source="{Binding Appointments,
                    Source={d:DesignInstance Type=dataModel:SampleDataSource,
                    IsDesignTimeCreatable=True}}">
    <CollectionViewSource.GroupDescriptions>
        <PropertyGroupDescription PropertyName="@DateOfVisit" />
      </CollectionViewSource.GroupDescriptions>
</CollectionViewSource>
根据CollectionViewSource,应具有此字段。
我做错了什么?

这是用于winrt的CollectionViewSource的文档页面:

GroupDescriptions属性在WinRT中不可用

如果我没记错的话,这应该对你有用:

<CollectionViewSource x:Name="groupedAppointments" IsSourceGrouped="True"
                      ItemsPath="ThePropertyThatIsGroupedByDateOfVisitGoesHere"
                      d:Source="{Binding Appointments,
                    Source={d:DesignInstance Type=dataModel:SampleDataSource,
                    IsDesignTimeCreatable=True}}">   
</CollectionViewSource>

<CollectionViewSource x:Name="groupedAppointments" IsSourceGrouped="True"
                      ItemsPath="ThePropertyThatIsGroupedByDateOfVisitGoesHere"
                      d:Source="{Binding Appointments,
                    Source={d:DesignInstance Type=dataModel:SampleDataSource,
                    IsDesignTimeCreatable=True}}">   
</CollectionViewSource>