Here I’m going to show how you can use class libraries so you can use the same code across multiple applications. This can save time on typing multiple lines of the same code across different types of applications. For the example I’ll use code from a class library in an ASP form along with a Windows application. Now you might run into some issues along the way. Such as formatting that I ran into going from an ASP application to a WinForm application.
You can find the source code to both the ASP and C# Winforms Downloads section.