Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Microsoft .NET Framework 4.0 JumpList / TaskbarItemInfo example for Windows Forms

It is my understanding that JumpList implementation using Windows API Code Pack is now depreciated as Microsoft now supports JumpList directly through Microsoft .NET Framework 4.0.

http://msdn.microsoft.com/en-us/library/system.windows.shell.taskbariteminfo.aspx

I can see that it is possible to set progress etc. to the Taskbar Item in their examples; however I have struggled so much to implement this on a Windows Form.

I had successfully managed to implement JumpList and TaskBarItem progress using Windows API Pack in the past http://code.google.com/p/zscreen/source/browse/trunk/ZScreen/Forms/ZScreenConfigGUI.cs#277 but I want to move away from this dependency and utilise the Microsoft .NET Framework 4.0 instead.

Your advice is much appreciated.

Thanks Mike

like image 326
McoreD Avatar asked Feb 10 '12 01:02

McoreD


1 Answers

System.Windows.Application is in the presentation framework(PresentationFramework.dll) i.e. WPF. It does not exist in Winforms. So use Windows API Code Pack like here: http://code.msdn.microsoft.com/windowsdesktop/Jump-List-with-Windows-db005b99

WPF 4 provides a native support for Jump List. Instead, if we use Windows Forms, we must adopt the Windows API Code Pack, a managed wrapper that allows to access to the Windows API functions. Available on NuGet too, it provides all you need to manage Jump Lists within our Windows Forms Applications.

Another example here: http://www.codeproject.com/Articles/103913/How-to-Create-a-Custom-Jumplist-with-Custom-Events

It is my understanding that JumpList implementation using Windows API Code Pack is now depreciated

Its not deprecated, its also a part of new .net 4 features but for WPF. For winforms, you will still have to use the pack like mentioned above.

like image 145
Vrashabh Irde Avatar answered Oct 24 '22 03:10

Vrashabh Irde