跳转列表不适用于C#App

我正在尝试在我的C#应用​​程序中使用Recent和Frequent JumpLists.我正在使用Windows API Codepack v1.1(http://code.msdn.microsoft.com/WindowsAPICodePack).我每次应用程序启动时都会初始化JumpLists,每次在应用程序中打开项目时,我都会将AddRecent()初始化为JumpList.

有些东西丢失了,因为右键单击任务栏中的应用程序图标时,JumpLists根本就不显示.我有一个文件出现一次,但就是这样!

初始化:

    private void InitializeJumpLists()
    {
        if (TaskbarManager.IsPlatformSupported)
        {
            JumpList recentJumpList = null;
            JumpList frequentJumpList = null;

            TaskbarManager.Instance.ApplicationId = Application.ProductName;

            recentJumpList = JumpList.CreateJumpList();
            recentJumpList.KNownCategoryTodisplay = JumpListKNownCategoryType.Recent;
            recentJumpList.Refresh();

            frequentJumpList = JumpList.CreateJumpList();
            frequentJumpList.KNownCategoryTodisplay = JumpListKNownCategoryType.Frequent;
            frequentJumpList.Refresh();
        }
    }

开放项目:

    private void OpenProject(string path, bool isFromrecentFilesList)
    {
        DialogResult result = ConfirmProjectClosing();

        if (result == DialogResult.Yes)
            Save();
        else if (result == DialogResult.Cancel)
            return;

        using (new Wait())
        {
            //Code here opens the project, etc.

            //Try to add the file to the Jump List.
            if (TaskbarManager.IsPlatformSupported)
                JumpList.AddToRecent(path);

            //Code here finished up.
        }
    }

我错过了什么?

解决方法:

this page与您所看到的问题有什么关系?

相关文章

Windows2012R2备用域控搭建 前置操作 域控主域控的主dns:自...
主域控角色迁移和夺取(转载) 转载自:http://yupeizhi.blo...
Windows2012R2 NTP时间同步 Windows2012R2里没有了internet时...
Windows注册表操作基础代码 Windows下对注册表进行操作使用的...
黑客常用WinAPI函数整理之前的博客写了很多关于Windows编程的...
一个简单的Windows Socket可复用框架说起网络编程,无非是建...