您可以使用 Silverlight 启动外部进程吗? [英] Can you start an outside process with Silverlight?

查看:53
本文介绍了您可以使用 Silverlight 启动外部进程吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

System.Diagnostics 程序集是 Silverlight CLR 框架的一部分,但它只包含与调试相关的类,Process 类不可用.有没有其他方法可以从 Silverlight 应用程序启动外部进程?

The System.Diagnostics assembly is part of the Silverlight CLR framework, but it only includes classes related to debugging, the Process class is not available. Is there any other way to start an outside process from a Silverlight application?

推荐答案

是的,您可以在 Silverlight 4(在具有提升的完全信任的浏览器外)中,例如:

Yes, you can in Silverlight 4 (in out-of-browser with elevated full trust), example:

dynamic cmd = AutomationFactory.CreateObject("WScript.Shell");
cmd.Run("calc.exe", 1, true);

这篇关于您可以使用 Silverlight 启动外部进程吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆