Visual Studio uses Projects as the unit of compilation, hence all files within a project would get compiled into either an Exe or Dll. Hence you use multiple projects to seperate out classes that need to be in a library vs classes that need to be in an application.
You need to add a class library to your solution and then add a reference to that library.
To do this, do the following:
1. Open your solution 2. Choose File -> Add -> New Project 3. Under the Visual C# node, choose the Windows node and select Class Library 4. Enter a name for the library and click OK 5. In Solution Explorer, right-click the References node under your orginal Windows Application project and choose Add Reference 6. Select the Projects tab and select the new Class Library you created 7. Click OK
You can now add classes to the Class Library project and use them within the Windows Application.
separate classes
Louis Somers
Regards,
Saurabh Nandu
www.MasterCSharp.com
www.AksTech.com
Zhila
You need to add a class library to your solution and then add a reference to that library.
To do this, do the following:
1. Open your solution
2. Choose File -> Add -> New Project
3. Under the Visual C# node, choose the Windows node and select Class Library
4. Enter a name for the library and click OK
5. In Solution Explorer, right-click the References node under your orginal Windows Application project and choose Add Reference
6. Select the Projects tab and select the new Class Library you created
7. Click OK
You can now add classes to the Class Library project and use them within the Windows Application.
duphusMVP