如何获得在正在内的安装程序类的MSI安装路径 [英] How to get the path where MSI is being installed within installer class
本文介绍了如何获得在正在内的安装程序类的MSI安装路径的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我添加了一个安装程序类和类中的即时覆盖安装方法。在这个方法我想正在安装MSI的路径? (Directory用户选择安装应用程序)?
我尝试以下,这让我空字符串,
字符串s = Context.Parameters [SRCDIR];
解决方案
我终于找到了如何从安装程序类获得目标目录路径
字符串安装路径= this.Context.Parameters [assemblypath];
I have added an Installer class and within the class i'm overriding Install method. Within this method i want to get the path where MSI is being installed? (Directory user have chosen to install the application) ?
I tried the following and it gives me empty string,
string s = Context.Parameters["SrcDir"];
解决方案
I finally found how to get the target directory path from installer class
string installationPath = this.Context.Parameters["assemblypath"];
这篇关于如何获得在正在内的安装程序类的MSI安装路径的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文