I have a listview with two groups. The code is the same for Windows and Wpf applications, but when I show the listview, in Wpf application, there isn't grouping.

Here' the code:

private System.Windows.Forms.ListView listView1;
ListViewGroup group1 = listView1.Groups.Add(fur.GetHashCode().ToString(),
                    fur.GetType().ToString() + " - " + fur.Message);
//some more code
group1.Items.Add(something);

Recommended Answers

All 3 Replies

The WPF Listview is under System.Windows.Controls, so it is not the same as the Winforms Listview.

Aha, and what is to Wpf what Winforms Listview is to Windows apps?
Is it DataGrid?
I need to do grouping.

Problem solved :)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.