开发者

Windows Media Player Styled ListView

开发者 https://www.devze.com 2023-01-29 17:08 出处:网络
Hi I\'m working on a project and I\'d like to have large image displayed on the left and a regular list on the left, akin to Windows Media Player\'s Lis开发者_C百科tView in Album mode. (see image belo

Hi I'm working on a project and I'd like to have large image displayed on the left and a regular list on the left, akin to Windows Media Player's Lis开发者_C百科tView in Album mode. (see image below)

Windows Media Player Styled ListView

Does anyone know of where I can get a control that does this in VB.NET/C# in WinForms?


This is going to be extremely difficult to implement entirely by yourself in WinForms. As commenters have pointed out, this is a task perfectly suited for WPF, but presumably that's not an option in your case.

Therefore, I strongly recommend that you investigate the ObjectListView control. Here, most of the design and infrastructure have already been implemented for you, and all you'll have to do is tweak it to look like the Windows Media Player example.

As the linked page explains, several aspects of the ObjectListView are slightly different from the standard ListView control. The author claims it's better and more intuitive, but I honestly never have taken the time to make the switch (I'm not much on custom theming though, so there's been less need). Either way, it's important to note that it's "not a drop-in replacement". If your project isn't too far under development, I think you'll find this is definitely the way to go.

Plus, it's free and the source code is available. That makes it a big winner in my book.

Just for fun, here's a sample of what you can do in ObjectListView with relative ease:

Windows Media Player Styled ListView


I dont think you can do this in WinForms as it is pretty restrictive [Unless you embed a WPF control in WinForms, which pretty much invalidates the objective of using WinForms altogether IMHO]... you could use a listbox with a datatemplate and a couple of bindings and it will work, but if you really need it to be a Grid-Like thing you should dig into the DataGrid:

http://msdn.microsoft.com/en-us/library/system.windows.controls.datagrid%28VS.95%29.aspx#

Take in account the DataGrid is a .NET4/WPF CodePlex Pack-only Control :)

0

精彩评论

暂无评论...
验证码 换一张
取 消