I have used setup project of VS 2010 to build setup (msi) of one of my application.
I want to install application to the exact location where my msi is. If my msi is in D:\\Application folder and someone executes it, it should install the application to that same folder. I know for that I have to go to Setup Properties > View > File System > Application Folder. For Application Folder, I'll have to set DefaultLocation property.
But what should I set as value so that my msi installs the application to the exact location from where it is being executed.
Put [SourceDir] as the default location. That's case-sensitive, as are all Windows Installer properties.
https://msdn.microsoft.com/en-us/library/windows/desktop/aa371857(v=vs.85).aspx
I tested this and it works fine. Note that - you'll see the folder name in the browse dialog if you don't hide it, therefore the user could change it.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.