I have a rather loaded question regarding a library/framework my company uses to build websites from that I hope I can convey without too much trouble.
Present Situation: Currently, we have a solution in VS 2010 that has a Web Project, "Framework_Web", which currently contains all the web pages in the application as well as other s开发者_运维问答tuff like images folder, web.config. The web project includes pages that should be shared across all applications and pages specific to the application. We also have a class library project, "Framework_Library" that contains all the framework code that should be shared across applications. It produces an assembly "Framework_Library" and uses the namespace "Framework_Library".
When a developer wants to create a new application AppY, we used to copy the solution from a previously built application AppX (yes I know, really stupid) and modify it as need be for AppY.
Question: The question I have is, how do I create a new application AppY, such that AppX and AppY are able to have thier own webpages and web.config, yet share the core framework (web pages, class library).
Current Roadmap: So now that we are using VS 2010 Team Foundation Studio, we want to create a Base Framework Solution as a TFS Team Project (e.g. "Base_Framework") that contains all the webpages, etc. for the core of the framework as a web project. Also, I want to include the "Framework_Library" into this solution. Then for each application (e.g. AppX) we can create a new Team Project. This would allow us to manage the core framework web pages & code seperate from each of the applications that utilize it. Sharing the "Framework_Library" class library between applications is trivial because it's packaged as an assembly. But, I'm not sure how to share the web project?
- Create a project that creates a class library with the "Framework_Library".
- In your new Web Applications Add a reference to the Framework_Libraray project.
- On sharing web pages, you can create a base class with similar that can be compiled into the Framework_Library Project and inherited to to your web pages. But I do not think sharing full web pages will work. You will probably have to copy the pages.
精彩评论