Link to home
Start Free TrialLog in
Avatar of Jamil Muammar
Jamil Muammar

asked on

.NET Convert Console Application to referance Project

Hi Experts,
 I have a .NET soluation contain 2 project

first Console Application
second WEB application

How do I set the Console Application as refreance to the Web Application


Thanks
Avatar of Ryan Chong
Ryan Chong
Flag of Singapore image

do you mean to create a class library and use it in your 2nd web application?
Avatar of Jamil Muammar
Jamil Muammar

ASKER

yes
Don't do this.

Cause setting a reference means code reuse.

In this case create a new project, type class library.
Set a reference in your console application and your ASP.NET application to that class library.
Then you refactor your console application and move all code, you want to share, to that class library.
And when you want good, clean code, then you also create a UnitTest project for your class library.

Adding a reference:User generated image
ASKER CERTIFIED SOLUTION
Avatar of Ryan Chong
Ryan Chong
Flag of Singapore image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial