安装我的应用程序时如何区分x86和x64操作系统

时间:2021-06-21 03:17:00

I have an application, I finished it I created setup but I encountered a problem.

我有一个应用程序,我完成它我创建了设置但我遇到了一个问题。

I have a few Prerequistes ( net framework4.5,Sql Server Express 2008 r2 ) I put both Sql Server Express 2008 r2 x64 and x32 in setup - I did this in the case the user does not have Internet Connection, but how do I know the client machine runs on x64 operating system, and how to make the application choose the good one.

我有一些Prerequistes(net framework4.5,Sql Server Express 2008 r2)我把Sql Server Express 2008 r2 x64和x32都安装好了 - 我这样做是因为用户没有Internet连接,但我怎么知道客户端机器在x64操作系统上运行,以及如何使应用程序选择好的应用程序。

Example: If client machine has x64 the setup should perform a silent install with the x64 version of Sql Server Express 2008 r2, and so on. Thank you

示例:如果客户端计算机具有x64,则安装程序应使用x64版本的Sql Server Express 2008 r2执行静默安装,依此类推。谢谢

1 个解决方案

#1


2  

from here

从这里

Install a component or run a custom action based on the Windows OS type (32-bit or 64-bit) This can be done by using the VersionNT64 property in the "Condition" field for a component or the "Expression" field for a custom action.

安装组件或基于Windows操作系统类型(32位或64位)运行自定义操作可以通过在组件的“条件”字段中使用VersionNT64属性或为自定义使用“表达式”字段来完成此操作行动。

If the component (or custom action) should be installed (or run) only on a 32-bit system, the condition is:

如果应仅在32位系统上安装(或运行)组件(或自定义操作),则条件为:

NOT VersionNT64 If the component (or custom action) should be installed (or run) only on a 64-bit system, the condition is:

NOT VersionNT64如果应仅在64位系统上安装(或运行)组件(或自定义操作),则条件为:

VersionNT64

VersionNT64

#1


2  

from here

从这里

Install a component or run a custom action based on the Windows OS type (32-bit or 64-bit) This can be done by using the VersionNT64 property in the "Condition" field for a component or the "Expression" field for a custom action.

安装组件或基于Windows操作系统类型(32位或64位)运行自定义操作可以通过在组件的“条件”字段中使用VersionNT64属性或为自定义使用“表达式”字段来完成此操作行动。

If the component (or custom action) should be installed (or run) only on a 32-bit system, the condition is:

如果应仅在32位系统上安装(或运行)组件(或自定义操作),则条件为:

NOT VersionNT64 If the component (or custom action) should be installed (or run) only on a 64-bit system, the condition is:

NOT VersionNT64如果应仅在64位系统上安装(或运行)组件(或自定义操作),则条件为:

VersionNT64

VersionNT64