WinForm 桌面任务栏右键菜单

实现效果
image

image

需要载入这个包
image

代码

using Microsoft.WindowsAPICodePack.Taskbar

private void Form1_Load(object sender,EventArgs e)
{
	JumpList jumpList = JumpList.CreateJumpListForIndividualWindow("",this.Handle);
	jumpList.AddUserTasks(new JumpListLink(@"E:\1.txt","任务1"));

}

https://docs.microsoft.com/en-us/windows/win32/shell/taskbar-extensions

posted @ 2022-08-31 14:28  Topi  阅读(129)  评论(0)    收藏  举报