Vista explorer / folder view

I am trying to have a list of large (256x256) icons in a list similar to vista explorer, but the listform winforms control is not like vista listview.

Before I go into WPF, can someone tell me if viewing a WPF list can do this?

I basically get this (solid blue selection):

alt text

instead (translucent blue selection):

alt text http://i42.tinypic.com/2zzmfk7.png

Can this be done using WinForms?

Btw I am using Windows 7.

+5
source share
2 answers

Not sure about WPF, but in WinForms you have to apply the "explorer" theme to your list in order to achieve an Explorer-like interface.

[DllImport("uxtheme.dll")]
public extern static int SetWindowTheme(
    IntPtr hWnd,
    [MarshalAs(UnmanagedType.LPWStr)] string pszSubAppName,
    [MarshalAs(UnmanagedType.LPWStr)] string pszSubIdList);

SetWindowTheme(listView.Handle, "explorer", null);
+5

, WPF; , MSDN: ListView.

.

, WinForms.

: . MSDN ListView, .

+1

All Articles