Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > Avalon

Vista - Grouping and sorting with CollectionViewSource inside the Nov CTP?

 
 
Old 01-10-2006   #1 (permalink)
Philippe Lavoie


 
 

Grouping and sorting with CollectionViewSource inside the Nov CTP?

Hi

I'm trying to get grouping and sorting working with the Nov CTP and I
can't find any up-to-date documentation on that class. Can someone point
me to a working sample?

Many thanks

Phil

My System SpecsSystem Spec
Old 01-10-2006   #2 (permalink)
Tina Tam [MSFT]


 
 

Re: Grouping and sorting with CollectionViewSource inside the Nov CTP?

Hi Philippe,

If you have the Nov CTP SDK documentation, you should be able to see an
example on the CollectionViewSource class page (with a link to a
CollectionViewSource sample), or is that not what you're looking for?
Here's a snippet from that example:
<Window.Resources>

<src:Places x:Key="places"/>

<CollectionViewSource Source="{StaticResource places}" x:Key="cvs">
<CollectionViewSource.SortDescriptions>
<scm:SortDescription PropertyName="CityName"/>
</CollectionViewSource.SortDescriptions>
<CollectionViewSource.GroupDescriptions>
<dat:PropertyGroupDescription PropertyName="State"/>
</CollectionViewSource.GroupDescriptions>
</CollectionViewSource>

</Window.Resources>
<DockPanel>
<ListBox ItemsSource="{Binding Source={StaticResource cvs}}"
DisplayMemberPath="CityName" Name="lb">
<ListBox.GroupStyle>
<x:Static Member="GroupStyle.Default"/>
</ListBox.GroupStyle>
</ListBox>
</DockPanel>Thanks,
Tina
--
This posting is provided "AS IS" with no warranties, and confers no rights.

"Philippe Lavoie" <philippe.lavoie@cactus.ca> wrote in message
news:%23xOBSbNAGHA.3936@TK2MSFTNGP12.phx.gbl...
> Hi
>
> I'm trying to get grouping and sorting working with the Nov CTP and I
> can't find any up-to-date documentation on that class. Can someone point
> me to a working sample?
>
> Many thanks
>
> Phil



My System SpecsSystem Spec
Old 01-10-2006   #3 (permalink)
Philippe Lavoie


 
 

Re: Grouping and sorting with CollectionViewSource inside the NovCTP?

Thanks Tina

I was so sure that the samples were not working that I didn't even
bother looking there Instead I looked on the web and none of the
information works with the Nov CTP (even MSDN which is kind of strange).

I will look there next time

Phil

Tina Tam [MSFT] wrote:
> Hi Philippe,
>
> If you have the Nov CTP SDK documentation, you should be able to see an
> example on the CollectionViewSource class page (with a link to a
> CollectionViewSource sample), or is that not what you're looking for?
> Here's a snippet from that example:
> <Window.Resources>
>
> <src:Places x:Key="places"/>
>
> <CollectionViewSource Source="{StaticResource places}" x:Key="cvs">
> <CollectionViewSource.SortDescriptions>
> <scm:SortDescription PropertyName="CityName"/>
> </CollectionViewSource.SortDescriptions>
> <CollectionViewSource.GroupDescriptions>
> <dat:PropertyGroupDescription PropertyName="State"/>
> </CollectionViewSource.GroupDescriptions>
> </CollectionViewSource>
>
> </Window.Resources>
> <DockPanel>
> <ListBox ItemsSource="{Binding Source={StaticResource cvs}}"
> DisplayMemberPath="CityName" Name="lb">
> <ListBox.GroupStyle>
> <x:Static Member="GroupStyle.Default"/>
> </ListBox.GroupStyle>
> </ListBox>
> </DockPanel>Thanks,
> Tina



My System SpecsSystem Spec
Old 01-10-2006   #4 (permalink)
Tina Tam [MSFT]


 
 

Re: Grouping and sorting with CollectionViewSource inside the Nov CTP?

Ah, I see. Just FYI, MSDN has a different refresh schedule. The content
there is only refreshed when there is a major milestone (such as a beta, but
not a CTP). Therefore the Nov CTP SDK docs are more up-to-date than the
online docs.

Also, the samples that don't compile in the Nov version of the SDK are
documented here:
http://download.microsoft.com/downlo...K%20Readme.htm

Hope that helps,
Tina
--
This posting is provided "AS IS" with no warranties, and confers no rights.

"Philippe Lavoie" <philippe.lavoie@cactus.ca> wrote in message
news:uWtu5iYAGHA.2036@TK2MSFTNGP14.phx.gbl...
> Thanks Tina
>
> I was so sure that the samples were not working that I didn't even bother
> looking there Instead I looked on the web and none of the information
> works with the Nov CTP (even MSDN which is kind of strange).
>
> I will look there next time
>
> Phil
>
> Tina Tam [MSFT] wrote:
>> Hi Philippe,
>>
>> If you have the Nov CTP SDK documentation, you should be able to see an
>> example on the CollectionViewSource class page (with a link to a
>> CollectionViewSource sample), or is that not what you're looking for?
>> Here's a snippet from that example:
>> <Window.Resources>
>>
>> <src:Places x:Key="places"/>
>>
>> <CollectionViewSource Source="{StaticResource places}" x:Key="cvs">
>> <CollectionViewSource.SortDescriptions>
>> <scm:SortDescription PropertyName="CityName"/>
>> </CollectionViewSource.SortDescriptions>
>> <CollectionViewSource.GroupDescriptions>
>> <dat:PropertyGroupDescription PropertyName="State"/>
>> </CollectionViewSource.GroupDescriptions>
>> </CollectionViewSource>
>>
>> </Window.Resources>
>> <DockPanel>
>> <ListBox ItemsSource="{Binding Source={StaticResource cvs}}"
>> DisplayMemberPath="CityName" Name="lb">
>> <ListBox.GroupStyle>
>> <x:Static Member="GroupStyle.Default"/>
>> </ListBox.GroupStyle>
>> </ListBox>
>> </DockPanel>Thanks,
>> Tina

>
>



My System SpecsSystem Spec
 

Thread Tools


Similar Threads
Thread Forum
grouping / sorting files General Discussion
grouping shapes with lines inside Vista General
Task Bar Grouping not working, box is checked, 11 windows, no grouping...HELP! TIA Vista General
Sorting, grouping data PowerShell


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46