473,782 Members | 2,448 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

assembleys having the same identities

Bellow is a snippet from the ms website about using loadfile on
assemblies that have the same identities.

I beleive this "identity" issue may be the cause of a problem i have
using the alternative Loadfrom option to load the assembly.

Cany anyone explain to me what this "identity" issue is, how it
relates to creating multiple DLL's in c#, and how does it differ in
the use of loadfile and loadfrom
any advice appreciated

thanks

Peted

Quote:
Use the LoadFile method to load and examine assemblies that have the
same identity, but are located in different paths. LoadFile does not
load files into the LoadFrom context, and does not resolve
dependencies using the load path, as the LoadFrom method does.
LoadFile is useful in this limited scenario because LoadFrom cannot be
used to load assemblies that have the same identities but different
paths; it will load only the first such assembly.

Feb 21 '07 #1
1 1323
Hi,

Peted wrote:
Bellow is a snippet from the ms website about using loadfile on
assemblies that have the same identities.

I beleive this "identity" issue may be the cause of a problem i have
using the alternative Loadfrom option to load the assembly.

Cany anyone explain to me what this "identity" issue is, how it
relates to creating multiple DLL's in c#, and how does it differ in
the use of loadfile and loadfrom
See this article, it's very good:

http://www.gotdotnet.com/team/clr/Lo...Isolation.aspx

The snippet hereunder states that LoadFile doesn't have that problem, so
you probably should use LoadFile instead of LoadFrom when possible.
However, there are cases where LoadFrom must be used, for example if the
assembly you want to load is located on a different server (in the case
of a web application for example).

HTH,
Laurent
any advice appreciated

thanks

Peted

Quote:
Use the LoadFile method to load and examine assemblies that have the
same identity, but are located in different paths. LoadFile does not
load files into the LoadFrom context, and does not resolve
dependencies using the load path, as the LoadFrom method does.
LoadFile is useful in this limited scenario because LoadFrom cannot be
used to load assemblies that have the same identities but different
paths; it will load only the first such assembly.
--
Laurent Bugnion [MVP ASP.NET]
Software engineering, Blog: http://www.galasoft-LB.ch
PhotoAlbum: http://www.galasoft-LB.ch/pictures
Support children in Calcutta: http://www.calcutta-espoir.ch
Feb 22 '07 #2

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

Similar topics

0
328
by: Nathan Baulch | last post by:
I have a windows app that has a few Interop assemblies. If I run it on a machine that doesn't have the required COM libraries, I get nasty COMExceptions. What I would like to do is check to see if the required libraries are registered when first starting my app. As I couldn't find an easy way to do this, I thought I might just get the Identities of each of the ActiveX type assembly references using reflection and look them up in...
0
907
by: Picho | last post by:
Hi all, I am trying to write a secure application and some of you have been very helpful on that subject. the only question remaining open after implementing certain methodologies is this: from a hacker point of view, is it possible to impersonate to SYSTEM or ASPNET windows identities on a local machine?
6
1606
by: CJ | last post by:
Okay, same program, different issue. Thanks to the help that I was given I was able to complete my program to find variables in a list that were repeated, and display them once, and how many times they appeared in the list. And it worked great! But, being the perfectionist that I am, I wanted to make the proggie allow any size of list, and not have to be recoded every time. So step one was to not make the program reliant on the list...
4
2749
by: don | last post by:
I have two existing interfaces having methods with same names. Now I have to implement both intrfaces in one class. Is there any way I could implement methods with same names in both interfaces without getting errors from the compiler?
3
1707
by: Henrik Dahl | last post by:
Hello! From default, the ASPNET user is giving the process identity for the ASP.NET runtime environment of IIS, however it's possible to change the user by modifying the <processModel> element in the machine.config file. Is it possible to have multiple IIS servers running, each with their own user specified for the process identity or to specify the process identity specifically for each of the ASP.NET WebForms applications run by a...
7
2101
by: Andrew Christiansen | last post by:
Hey everyone. I have Visual Basic .NET 2003 and am trying to show images on a treeview control. I have the imagelist on the form filled with images, and have the ImageList property of the treeview control set to the imagelist containing the images I want to be displayed next to each node. It seems that no matter what I do there will be no images displayed next to the nodes during runtime. I tried creating nodes during designtime using...
5
1871
by: David Smithz | last post by:
Hi there, From a customer database table, I need to get a list of all the customers that have the same birthdays and their names. While I can get a count of this and the name of one of the customers of the group sharing the same birthday by using the following code: SELECT ALL count(dob) AS DOBcount, dob, firstname, lastname FROM accounts
46
2453
by: Your Uncle | last post by:
About a month ago, Heathfield posted the peudosource for random permuting from TAOCP. It was all of maybe five lines. You needed to be able to do two things: be able to get a random number in a range and swap. I remembered that Dan Pop taught me to write the swap as a macro. With forum improvements, this became: #define SWAP(m, n) (tmp = (m), (m) = (n), (n) = tmp) The random number comes, again with forum improvements: int...
3
1824
by: Steve | last post by:
Hi; We just migrated to SqlServer 2005. When I import tables from from SqlServer database into another the identity fields get switched off from being identities. How can I prevent that from happening? Thanks in advance for any information
0
9639
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10311
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
10146
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...
0
9942
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
6733
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();...
0
5378
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5509
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4043
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
2874
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.