如何在installshield中删除默认的INSTALLDIR

时间:2022-06-01 17:44:35

I have a Basic MSi project in installshield 2012 that allows the user to change the installation path, the default installation path is a fixed path C:\xxx directory. The problem is that if the user decides to install the application in another location that the default C:\xxx folder the system will do that, but it will also create and empty C:\xxx folder! How can I prevent this?

我在installshield 2012中有一个Basic MSi项目,允许用户更改安装路径,默认安装路径是固定路径C:\ xxx目录。问题是如果用户决定在另一个位置安装应用程序,系统会默认C:\ xxx文件夹,但它也会创建并清空C:\ xxx文件夹!我怎么能阻止这个?

with regards, Ehsan

关于,Ehsan

1 个解决方案

#1


2  

In the components panel you need to go through all the components and on each one change the "Destination" field from C:\xxx to [INSTALLDIR]xxx.

在组件面板中,您需要遍历所有组件,并在每个组件上将“目标”字段从C:\ xxx更改为[INSTALLDIR] xxx。

The is problem that a component, possibly a registry component or SQL component, has a "Destination" of C:\xxx and even though no files are copied as part of the component InstallShield still creates the folder.

问题是组件(可能是注册表组件或SQL组件)具有C:\ xxx的“目标”,即使没有文件作为组件的一部分进行复制,InstallShield仍会创建该文件夹。

#1


2  

In the components panel you need to go through all the components and on each one change the "Destination" field from C:\xxx to [INSTALLDIR]xxx.

在组件面板中,您需要遍历所有组件,并在每个组件上将“目标”字段从C:\ xxx更改为[INSTALLDIR] xxx。

The is problem that a component, possibly a registry component or SQL component, has a "Destination" of C:\xxx and even though no files are copied as part of the component InstallShield still creates the folder.

问题是组件(可能是注册表组件或SQL组件)具有C:\ xxx的“目标”,即使没有文件作为组件的一部分进行复制,InstallShield仍会创建该文件夹。