开发者

Sharing Source Code Across Projects in a Solution

Just clarifying something, forgive the novice question.

I've got some source code that applies to multiple projects within a given Visual Studio solution. Best practice suggests I create another project within the solution "ApplicationBase", put the source code there, compile it and reference the dll in the other projects?

开发者_运维知识库

This is my first time doing a multi-project solution, so I just want to make sure.


Yes, this is correct. The best practice is to not share "source code", but rather to place the shared code into a separate, class library project, and then to reference that project in more than one place.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜