Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我只是在 WPF 应用程序的按钮单击事件中运行一小段代码。
该代码只是连接到数据库以检索图像并显示在表单上。
但是,我收到此请求,以获得“System.Web.AspNetHostingPermission Exception..
请帮我解决这个问题......非常感谢......
我听说这是不可能直接从 Silverlight 应用程序(我猜这也适用于 WPF XBAP),因为它是一个安全问题。
另一种方法是使用 WCF 服务并通过 WCF 服务检索数据。