Tag Archives: progressbar

How to display a progressbar in taskbar in C#

You might have noticed that programs display a progress bar in the taskbar a lot of times. This allows users to see the progression of the task even if the application is minimized by simply looking at the taskbar. Today I will be showing you a way to achieve that functionality so you can use it in your projects.

Taskbar progress bar

First you will need to download Windows API Code Pack for Microsoft .NET Framework. Extract the contents of the file and search for Microsoft.WindowsAPICodePack.Shell.dll which is located under the binaries folder.

Add Microsoft.WindowsAPICodePack.Shell.dll as a reference to your project. This will allow you to use the namespaces which are required in order to display the progress bar.

The code below is an example on how you can implement the feature.

How to download a file in C# (progressbar and download speed)

This is a simple snippet that will allow you to download a file from the internet in C# while being able to display the download percentage, download speed and the amount of total data received while downloading.

This is the example form of what to expect when you have the code in place: