简体   繁体   English

在ASP.NET中的其他AppDomain中运行应用程序

[英]Run application in other AppDomain in ASP.NET

I have an ASP.NET application in which 5 sub - apps are running. 我有一个ASP.NET应用程序,其中有5个子应用程序正在运行。 I want one sub application to run in the other domain. 我希望一个子应用程序在另一个域中运行。 I tried creating a new AppDomain: 我尝试创建一个新的AppDomain:

AppDomain domain = AppDomain.CreateDomain("MyDomain");

When I try to retrieve FriendlyName by the following code: 当我尝试通过以下代码检索FriendlyName时:

System.Diagnostics.Debug.WriteLine(domain.FriendlyName);

I got this error: 我收到了这个错误:

Cannot obtain fields or call methods on the instance of type 'System.AppDomain' because it is a proxy to a remote object.

If I am getting it correctly then you nned to write a visualizer for that. 如果我正确地获得它,那么你肯定要为它编写一个可视化器。 It's a plugin for Visual Studio to "visualize" any watch value and you can do whatever you want to do in there, instead of in your actual project code. 它是Visual Studio的一个插件,用于“可视化”任何手表值,您可以在那里做任何你想做的事情,而不是在你的实际项目代码中。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM