473,396 Members | 2,158 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,396 software developers and data experts.

System.AppDomain.AppendPrivatePath(string) is obsolete

System.AppDomain.AppendPrivatePath(string) is obsolete :
AppDomain.AppendPrivatePath has been deprecated. Please investigate the use
of AppDomainSetup.PrivateBinPath instead.
From what I can see, using this recommended new approach restricts me to
adding the bin paths *before* I do anything else. My app only loads plugins
when told to by the user, by this time lots of other assemblies have loaded
etc. Googling on this subject has only revealed to me that plenty of people
are unhappy about this deprecation.

At the moment I am leaving this line of code in, but seeing as I hate
compiler warnings could someone tell me what the correct way of implementing
my requirement is?

Thanks very much.
Pete

Dec 16 '07 #1
1 2828
Well, are you loading all of the plug-ins in a single app domain? I
think the correct way to do this would be to load a separate app domain for
each plugin (or group of plugins) that you want to load.

My guess is that the reason why AppendPrivatePath was obsoleted is that
it was viewed as a security risk, as once the code was loaded into another
app domain, it could append a private path and possibly modify how a known
assembly was loaded.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Peter Morris [Capable Objects]" <firstname + '.' +
la******@capableobjects.comwrote in message
news:uK**************@TK2MSFTNGP02.phx.gbl...
System.AppDomain.AppendPrivatePath(string) is obsolete :
AppDomain.AppendPrivatePath has been deprecated. Please investigate the
use of AppDomainSetup.PrivateBinPath instead.
From what I can see, using this recommended new approach restricts me to
adding the bin paths *before* I do anything else. My app only loads
plugins when told to by the user, by this time lots of other assemblies
have loaded etc. Googling on this subject has only revealed to me that
plenty of people are unhappy about this deprecation.

At the moment I am leaving this line of code in, but seeing as I hate
compiler warnings could someone tell me what the correct way of
implementing my requirement is?

Thanks very much.
Pete
Dec 16 '07 #2

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

Similar topics

27
by: Trep | last post by:
Hi there! I've been having a lot of difficult trying to figure out a way to convert a terminated char array to a system::string for use in Visual C++ .NET 2003. This is necessary because I...
15
by: Yifan | last post by:
Hi Does anybody know how to convert System::String* to char*? I searched the System::String class members and did not find any. Thanks Yifan
8
by: Ioannis Vranos | last post by:
In .NET (and C++/CLI) there is an overloaded String == operator for handles. That is when we do comparison of two String handles the contents of the Strings are compared instead of their addresses....
3
by: Imran Aziz | last post by:
Hello All, I am getting the following error on our production server, and I dont get the same error on the development box. Unable to cast object of type 'System.Byte' to type 'System.String'. ...
1
by: Marc | last post by:
Hi! I'm working with a C# client that calls a php web service. I've created a wrapper to call the service using .NET wsdl tool (adding a web reference). The call to the server works fine, it...
24
by: Marcus Kwok | last post by:
Hello, I am working on cleaning up some code that I inherited and was wondering if there is anything wrong with my function. I am fairly proficient in standard C++ but I am pretty new to the .NET...
2
by: Alejandro Aleman | last post by:
Hello! i know this may be a newbie question, but i need to convert a string from System::String^ to char*, in the msdn page tells how, but i need to set to /clr:oldSyntax and i dont want it...
4
by: John Smith | last post by:
How can I allow someone to cast my C# class into System.String? Is it possible in C#? In C++ I used "operator" keyword to mark C++ member function.
4
by: JamTech | last post by:
The Script Resource and the Web Resource files are generating intermittent errors in my application. I have been trying to chase the cause of the problem but to no avail. I notice that the “d”...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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...
0
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,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
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,...
0
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...
0
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...

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.