【发布时间】:2015-09-16 15:20:16
【问题描述】:
我正在将使用大量 .NET Remoting 的遗留系统转换为更现代的通信框架,并且我正在尝试在任何重大修订之前让它在本地运行。我的本地设置是Visual Studio 2013,我想托管在IIS Express。
我正在尝试处理此示例here 并接收NullReferenceException 从Props 提取凭据。看来ChannelServices.GetChannelSingProperties() 已返回null。
// GetChannelSinkProperties returns null
IDictionary Props = ChannelServices.GetChannelSinkProperties(service);
// NullReferenceException below
Props["credentials"] = CredentialCache.DefaultCredentials;
我会继续努力解决这个问题,但我希望那里的专家可以帮助我。
更多详情:
我的设置是 Visual Studio 2013,
新建了一个Console Application,将client和app.config放到这个项目中
创建了一个空 Web 应用程序,将服务器和 web.config 放置在此项目中
Visual Studio 在 localhost:53645 上托管我的站点,我已更改客户端 app.config 以同时访问 localhost 和 localhost:53645。
这应该行得通,对吧?
【问题讨论】:
标签: .net iis-express remoting