Wrox Programmer Forums
|
ASP.NET 1.x and 2.0 Application Design Application design with ASP.NET 1.0, 1.1, and 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.x and 2.0 Application Design section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 14th, 2005, 07:57 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 100
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to ~Bean~
Default Multiple Projects

I have a large ASP.NET web project which I want to divide into multiple projects. Reason being is there's a substantial portion of the project that is the Admin pages, and I want to develop and build those pages without interfering with the other pages which are constantly being tested by members of my team.

I started by splitting the main project into 3 pojects, say "main", "admin" and "classes". I did this by creating new projects in another instance os VS, then right clicking my main solution and seleting "Add->Existing Project". The only thing in the classes project are .vb classes, which are shared by both the admin and the main projects. I have the whole solution setup now, and all three projects appear in the Solution explorer pane. Per others recommendations I am not using any dll references between these.

I dont know if its relevant but:
Directory structure looks like:
/main/main.proj
/main/admin/admin.proj
/main/classes/classes.proj

and output directories are:
/main/bin/main.dll
/main/admin/bin/admin.dll
/main/classes/bin/classes.dll

The problem is that now all my references to the classes are broke. Any place that I reference any class in "classes" project from "admin" or "main" causes error: Type 'fooclass' is not defined.

What am I missing here?


-------------------------
Beware of programmers with screwdrivers...
__________________
-------------------------
Beware of programmers with screwdrivers...
 
Old October 14th, 2005, 09:50 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 100
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to ~Bean~
Default

I have got the app working now - well, partially anyway.

I found that I needed to add the projects as references as described here: http://msdn.microsoft.com/library/de...References.asp

So now my classes work fine. The project builds OK now too.

BUT...when I try to navigate to my Admin pages, I get the error: Parser Error Message: Could not load type 'foo'
Which confuses me because the project "admin" builds just fine, which tells me the DLL's are fine (I think).

???

Could it be some sort of Global.asax issue? I used these instructions here: http://www.codeproject.com/aspnet/sepmultweb.asp

-------------------------
Beware of programmers with screwdrivers...
 
Old October 14th, 2005, 10:23 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 100
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to ~Bean~
Default

OK...I found my problem...I did not reference the "admin" project from my "main" project, thus although all projects were building fine, the "admin.dll" was not neing moved into the main/bin...so the web app could not find the dll file and threw the Parser error.

oye!



-------------------------
Beware of programmers with screwdrivers...
 
Old October 17th, 2005, 07:59 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 100
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to ~Bean~
Default

After working with this for a few hours I really like having the projects split because it makes it easier to work with.

One thing that I thought I would be able to do, but apparently didn't put enough thought into, is that I wanted to be able to build one project without affecting my testers as they use another project. I think the problem is that I am using Session() variables to hold their login, and when I do a build of any of the (related) projects in my solution the server must be resetting all session variables (it boots everyone out from being logged in).

If anyone has taken the time to read through this thread I thank you...and if you have any suggestions about the above then I REALLY thank you!

-------------------------
Beware of programmers with screwdrivers...





Similar Threads
Thread Thread Starter Forum Replies Last Post
Deploying multiple projects in a single setup ken_jeff Pro Visual Basic 2005 1 July 2nd, 2006 09:53 PM
Deploying multiple projects in a single setup ken_jeff Pro VB.NET 2002/2003 0 June 30th, 2006 03:59 AM
Multiple Projects under Single Solution gadhiav ASP.NET 1.0 and 1.1 Professional 2 October 20th, 2005 04:26 AM
multiple projects within the solution(close Key) rosalynb VS.NET 2002/2003 1 September 28th, 2004 12:50 AM
how to handle multiple projects Ramakrishna.G General .NET 4 September 14th, 2004 12:31 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.