473,783 Members | 2,574 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Repost - Project's Referenced Non-GAC Assemblies

(Sorry for the repost, but I thought maybe I'd have better luck this
time)

I'm working on a utility to provide an overview of one's .NET projects
and one of the things I want to display is detailed information about
what each project references, whether it is assemblies in the GAC or
non-GAC assemblies or other .NET projects.

From the project file I can get the assembly names of all assemblies
referenced by a project, including other projects, via the
GetReferencedAs semblies method on the Assembly object, but there
seems to be no way to get from the assembly name to an actual
assembly object (since it's not in the GAC), without knowing the
path. I know that the referenced project probably has a dll in its
bin directory, but I don't know where that referenced project exists
- a referenced project's location isn't included in the project file
containing the reference.

Do I need to scan entire drives to find the referenced project's
assembly dll? This seems crazy - there must be an easy way to get to
the debug assemblies of referenced projects without knowing the
paths. I also don't want the user to have to indicate the solution
file - the project could be part of multiple solutions.

Nov 16 '05 #1
1 1494
Hi,

I think the information on all referenced assemblies, be it project
references or just plain assemblies should be available from the .csproj
file itself, so there is no need to use GetReferencedAs semblies.

On the other hand, you should consider the rules by which referenced
assemblies are located by the loader (there is a topic in the MSDN library
called something like "How the runtime locates assemblies").

--
Dmitriy Lapshin [C# / .NET MVP]
X-Unity Test Studio
http://www.x-unity.net/teststudio.aspx
Bring the power of unit testing to VS .NET IDE

"Jimi" <ji************ @yahoo-dot-ca.no-spam.invalid> wrote in message
news:40******** **@127.0.0.1...
(Sorry for the repost, but I thought maybe I'd have better luck this
time)

I'm working on a utility to provide an overview of one's .NET projects
and one of the things I want to display is detailed information about
what each project references, whether it is assemblies in the GAC or
non-GAC assemblies or other .NET projects.

From the project file I can get the assembly names of all assemblies
referenced by a project, including other projects, via the
GetReferencedAs semblies method on the Assembly object, but there
seems to be no way to get from the assembly name to an actual
assembly object (since it's not in the GAC), without knowing the
path. I know that the referenced project probably has a dll in its
bin directory, but I don't know where that referenced project exists
- a referenced project's location isn't included in the project file
containing the reference.

Do I need to scan entire drives to find the referenced project's
assembly dll? This seems crazy - there must be an easy way to get to
the debug assemblies of referenced projects without knowing the
paths. I also don't want the user to have to indicate the solution
file - the project could be part of multiple solutions.


Nov 16 '05 #2

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

Similar topics

1
3661
by: JoeS | last post by:
Is there anyway to share a single pch file between projects in VC 7.0? I have 300+ projects each of which creates its own pch. All projects include the exact same header files in the precompiled header. Its takes about 7 seconds to create the precompiled header for each project. That's 35 minutes spent creating precompiled headers for all project! All of the projects use PDB files for debug info. I tried creating Precomp.pch in project...
3
7368
by: Leith Bade | last post by:
I have been trying to use the new Visual C++ Toolkit 2003 with the VC6 IDE I set up the executable, inlcude, and library directories to point to the new compilers I had to fix a few errors in the MFC6 <afxtempl.h> to get it to compile with the better standards confomance (mainly omitted typename, and lazyness with specialized templates - using BASE_CLASS & TYPE instead of CObList & CObList*) Now I get some strange linker errors, and I don't...
14
2837
by: Steve McLellan | last post by:
Hi, Sorry to repost, but this is becoming aggravating, and causing me a lot of wasted time. I've got a reasonably large mixed C++ project, and after a number of builds (but not a constant number) linking (and sometimes compiling) becomes immensely slow, and task manager shows that link.exe (or cl.exe) is barely using any processor time, but an awful lot of RAM (around 150-200MB). I'm going to keep an eye on page faults since I can't...
5
4028
by: Jay A. Moritz | last post by:
Error: The dependency '<my dll>' in project '<my project>' cannot be copied to the run directory because it would conflict with dependency '<my dll>'. I am getting a dependency error building my application that was using some other namespaces that I had built and incorrectly referenced to the dll instead of the project, but I ended up removing the reference entirely but my project keeps getting the error. How do I tell my project to...
3
2891
by: noreponse1 | last post by:
Hello, I have a solution that contains two projects. I have 2 dlls that these projects use. Here's how it's set up: Solution -ProjectA --References ---DLLA -ProjectB
1
10359
by: iiitsunny | last post by:
i have ported one project which was working in VC6 to VC7. Now the project is working fine in VC7 also. I have made some additions in VC7 environment only. But the problem is that the project is not working in the release mode. I mean it is shooting off linking errors. I am required to generate an exe file and am looking for some suggestions!!! thank you all Linker Errors are something like this... error LNK2001: unresolved external...
6
2469
by: HJ | last post by:
Hi all, I am experiencing a weird issue and I hope you can help. We are using a Microsoft Access 2003 project (.ade) with an SQL Server 2000 database. One form contains a list box with the 'Table/View/StoredProc' row source type. The row source itself is a stored procedure. When an administrator opens this form, he sees data in the list box. Profiler shows a correct command 'EXEC <stored procedure<parameters>'. That is allright.
4
1472
by: DR | last post by:
when i build someone's project, and right click a function "goto definition" is disabled. how to reconfigure a .net project to support "goto definition" when i right click on function calls?
5
2824
by: ivarnelispam | last post by:
Hello all, I'm starting work on what is going to become a fairly substantial Python project, and I'm trying to find the best way to organize everything. The project will consist of: - A few applications - Several small scripts and utilities - Unit tests and small interactive test programs - A number of custom libraries and modules that may be shared and
4
17281
by: Dave Burns | last post by:
Hello, I am trying to specify a logical default value for a in a WCF Web Service using basicHttpBinding. I realize that the language defaults are: int - 0 string - null bool - false
0
10315
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10147
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10083
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9946
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8968
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7494
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6737
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
4044
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2877
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.