如何使用可能不存在一个.NET Framework版本安全检查.NET Framework版本? [英] How to safely check .NET Framework version using a .NET Framework version that may not exist?

查看:175
本文介绍了如何使用可能不存在一个.NET Framework版本安全检查.NET Framework版本?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经与.NET 3.5的应用程序。如果用户运行,而无需.NET 3.5的安装,我想有他们所看到的控制,也许提供了一个信息,即他们能够理解(有链接到.NET 3.5)与未处理的异常堆栈跟踪。但是,如果他们实际上并没有.NET 3.5如何让我的应用程序来控制什么?

I have an application built with .NET 3.5. If a user runs it without having .NET 3.5 installed, I want to have control of what they see and perhaps provide a message that they can understand (with a link to .NET 3.5) versus unhandled exception stack traces. But if they don't actually have .NET 3.5 how can my application control anything?

推荐答案

更​​重要的是,你可以使用一个安装程序技术,如维克斯或Visual Stuido安装项目,在安装过程中会检查所有的prerequisites你软件,如特定.NET框架运行时存在。如果不是,它会安装它们,或者至少告诉用户哪里得到他们,下一步该怎么做。

Better yet, you could use an installer technology, such as Wix or a Visual Stuido setup project, that checks during installation that all the prerequisites for you software, such as a particular .NET framework runtime exist. If not, it will install them, or at least tell the user where to get them and what to do next

这篇关于如何使用可能不存在一个.NET Framework版本安全检查.NET Framework版本?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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