473,386 Members | 1,694 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Add Reference problems again...

This is definitely a major weak spot in VS 2005 .NET development. It was a
big problem in VS 2003 and apparently has carried over to VS 2005. It
really should NOT be this complicated (it wasn't prior to .NET).

I've got a several core DLL references (class libraries) that I've added to
a Web application/solution. I try to build the solution and I get the
following:

Error 1 Unable to load referenced library
'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET
Files\MyWebApp\e3bfad37\_shadow\5c6fe0e9\bin\1\MyC ompanyName.Web.Utilities.dll':
The system cannot find the path specified.

I get a bunch of these errors for each of my core class library references
I've added to the web solution. I have NO idea what this directory is nor
why VS 2005 is even looking in this mysterious directory for any of my
DLLs -- I certainly didn't put them there.

These are then obviously followed up with a series of these errors:

Error 25 Type 'MyCompanyName.Web.Common' is not defined.
c:\inetpub\wwwroot\MyWebApp\App_Code\MyService.asm x.vb 68 30
http://localhost/MyWebApp/

because of the references that are "missing" from first slew of errors.

None of my code is currently under Source Control. If anyone has a solution
on the "correct" way to add References, please let me know. I've tried all
variations and none produce a clean working environment. What I'm trying to
accomplish is pretty simple, I retain a core set of DLLs (class libraries)
that live in a dir D:\NET Core\... and a web application that lives in
C:\inetpub\wwwroot\WebApp -- I've added references to pointing to D:\Net
Core and VS 2005 starts to go crazy and copy these core file everywhere (see
the mysterious "_shadow" directory) -- my questions

1. Why does VS 2005 copy files all over the place? Can this be prevented?
If so, how?
2. Why can't VS 2005 simply use the referenced DLL where I originally
specified?
3. When VS 2005 builds a debug or release for my web app, why can't it copy
the files it needs for final output and put them in the bin (rather than
creating all these hidden tempory ASP.NET dirs)?
4. What is the correct way to add a reference to my class libraries DLLs
and keep those references intact?

Fortunately I've read about many many other developers running into the same
situation. Apparently Microsoft has some "vision" about how this reference
process is supposed to work, but forgot to tell anyone about it.

Rob.
Feb 14 '06 #1
1 3895
I did find a sorta solution, but still no real understanding as to why I had
the problem in the first place. The "mystery" solution is to:

1. Select Property page for the web application (i.e.
http://localhost/MyWebApp)
2. Select "References"
3. Select all the listed DLLs and click the Update button

This removed all of the build errors.

It will be a nightmare when I actually have to add my code to Source
Control -- I've read about making sure NOTHING in my bin directory gets
added to source control. Not sure how this is supposed to my development
easier -- seems to have just over complicated this issue. So much so that I
think I'll just run command line compiles from now on and control it that
way. Good documentation of what VS 2005 does in this area is severly
lacking.

"Rob R. Ainscough" <ro*****@pacbell.net> wrote in message
news:uj**************@TK2MSFTNGP10.phx.gbl...
This is definitely a major weak spot in VS 2005 .NET development. It was
a big problem in VS 2003 and apparently has carried over to VS 2005. It
really should NOT be this complicated (it wasn't prior to .NET).

I've got a several core DLL references (class libraries) that I've added
to a Web application/solution. I try to build the solution and I get the
following:

Error 1 Unable to load referenced library
'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET
Files\MyWebApp\e3bfad37\_shadow\5c6fe0e9\bin\1\MyC ompanyName.Web.Utilities.dll':
The system cannot find the path specified.

I get a bunch of these errors for each of my core class library references
I've added to the web solution. I have NO idea what this directory is nor
why VS 2005 is even looking in this mysterious directory for any of my
DLLs -- I certainly didn't put them there.

These are then obviously followed up with a series of these errors:

Error 25 Type 'MyCompanyName.Web.Common' is not defined.
c:\inetpub\wwwroot\MyWebApp\App_Code\MyService.asm x.vb 68 30
http://localhost/MyWebApp/

because of the references that are "missing" from first slew of errors.

None of my code is currently under Source Control. If anyone has a
solution on the "correct" way to add References, please let me know. I've
tried all variations and none produce a clean working environment. What
I'm trying to accomplish is pretty simple, I retain a core set of DLLs
(class libraries) that live in a dir D:\NET Core\... and a web application
that lives in C:\inetpub\wwwroot\WebApp -- I've added references to
pointing to D:\Net Core and VS 2005 starts to go crazy and copy these core
file everywhere (see the mysterious "_shadow" directory) -- my questions

1. Why does VS 2005 copy files all over the place? Can this be
prevented? If so, how?
2. Why can't VS 2005 simply use the referenced DLL where I originally
specified?
3. When VS 2005 builds a debug or release for my web app, why can't it
copy the files it needs for final output and put them in the bin (rather
than creating all these hidden tempory ASP.NET dirs)?
4. What is the correct way to add a reference to my class libraries DLLs
and keep those references intact?

Fortunately I've read about many many other developers running into the
same situation. Apparently Microsoft has some "vision" about how this
reference process is supposed to work, but forgot to tell anyone about it.

Rob.

Feb 14 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: JoTo | last post by:
Hi Group, sorry for my for you surely dumb question. But i'm not so familiar with this reference- and pointerstew in C++ yet. Let me explain my problem with a little Codesnippet. If i do...
110
by: Mr A | last post by:
Hi! I've been thinking about passing parameteras using references instead of pointers in order to emphasize that the parameter must be an object. Exemple: void func(Objec& object); //object...
39
by: Mike MacSween | last post by:
Just spent a happy 10 mins trying to understand a function I wrote sometime ago. Then remembered that arguments are passed by reference, by default. Does the fact that this slowed me down...
6
by: T Koster | last post by:
After a few years of programming C, I had come to believe that I finally knew how to correctly organise my structure definitions in header files for mutually dependent structures, but I find myself...
11
by: Just Me | last post by:
I have a solution containing many usercontrol projects. When I wish to reference a usercontrol in another project I can select either the project or the assembly. Does it make a difference which...
3
by: Richard Lewis Haggard | last post by:
We are having a lot of trouble with problems relating to failures relating to 'The located assembly's manifest definition with name 'xxx' does not match the assembly reference" but none of us here...
2
by: raylopez99 | last post by:
I'm having problems compiling complex reference declarations in MSVC++.NET 2002 IDE. Here is an example: // --Foo.h-- #include "Bar.h" class Bar; //forward decl. to a class Bar in...
2
by: toton | last post by:
Hi, This is continuation of topic pointer & reference doubt. http://groups.google.com/group/comp.lang.c++/browse_thread/thread/df84ce6b9af561f9/76304d7d77f6ccca?lnk=raot#76304d7d77f6ccca But I...
42
by: dancer | last post by:
Using VB.net and ASP.net At runtime I receive the error that MANY people receive who are using much more complicated code than mine. "Object reference not set to an instance of an object. " ...
4
by: John Sheppard | last post by:
Hello there I was wondering if anyone could help me, I am trying to pass a typed dataset to a dialoged child form by reference. I have binding sources sitting on the child form. So to refresh...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.