A Library to create DeskBands on windows using C#. Deskbands are toolbars that are docked on the taskbar and provide additional functionality to an otherwise unused space.
CSDeskBand makes it easy to create a deskband using Winforms or WPF.
Images taken from the sample projects
Nuget packages are available here:
Use CSDeskBandWin
for winforms or CSDeskBandWpf
for wpf
- For a winforms usercontrol, inherit the
CSDeskBandWin
base class. See Sample.Win - For a wpf usercontol, Set
CSdeskBandWpf
as the root element in the XAML. See Sample.Wpf
Add [ComVisible(true)]
, [Guid("xx-xx-xx-xx-xx")]
, [CSDeskBandRegistration()]
attributes to the class
using CSDeskBand.Win;
using CSDeskBand;
[ComVisible(true)]
[Guid("5731FC61-8530-404C-86C1-86CCB8738D06")]
[CSDeskBandRegistration(Name = "Sample Winforms Deskband")]
public partial class UserControl1 : CSDeskBandWin
{
...
You need to start an elevated command prompt and be able to use regasm.exe
An easy way to do this is use the Developer Command Prompt for Visual Studio. Make sure that you use the correct version of regasm that matches your platform.
cd Sample.Win\bin\Debug
regasm /codebase Sample.Win.dll
The /codebase
switch will add the path of the dll into the registry entry.
Alternatively, register the assemblies into the Global Assembly Cache.
gacutil -i CSDeskBand.dll
gacutil -i CSDeskBand.Win.dll
gacutil -i Sample.Win.dll
regasm Sample.Win.dll
Note that GAC installation requires the assemblies to be Strong-Named
Check the Wiki for more details.
There are examples included for Winforms and WPF in the Sample.Win and Sample.Wpf projects
Tested on Windows 10 x64