Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/powershell/11.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
.net C#Winform的拇指按钮_.net_Winforms_Shell_Thumbnails - Fatal编程技术网

.net C#Winform的拇指按钮

.net C#Winform的拇指按钮,.net,winforms,shell,thumbnails,.net,Winforms,Shell,Thumbnails,我看到在WPF应用程序中,我们可以很容易地创建拇指按钮, 但我找不到任何方法使它在Winform应用程序中工作。到目前为止我已经试过了 using System.Windows.Shell; ... TaskbarItemInfo task = new TaskbarItemInfo(); ThumbButtonInfo button = new ThumbButtonInfo(); this.Controls.Add(button); //Error, I don't know how to

我看到在WPF应用程序中,我们可以很容易地创建拇指按钮, 但我找不到任何方法使它在Winform应用程序中工作。到目前为止我已经试过了

using System.Windows.Shell;
...
TaskbarItemInfo task = new TaskbarItemInfo();
ThumbButtonInfo button = new ThumbButtonInfo();
this.Controls.Add(button); //Error, I don't know how to add the ThumbButtonInfo to my winform.
我已经搜索过了,看到Winform有一个Windows API代码包,但我更喜欢System.Windows.Shell。然而,对于WindowsAPI代码包,我仍然不知道如何在winform中添加一个拇指按钮

所以我的问题是:如何向C#Winform应用程序添加一个简单的拇指按钮(最好只使用System.Windows.Shell)

谢谢你的阅读