cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
agshah
Level 7

INSTALLDIR - does the location exist or will be created

Hi all,

Once the user specified the install location (INSTALLDIR) I want to know if that location already exists or not.

But once the user specifies the location in 'Specify Destination Location'  dialog, and before I get a chance to check if it exists or not, InstallShield goes ahead and creates the install location. How do I find out if that location existed or was created by Installshield.

thanks.

 

Labels (1)
0 Kudos
(5) Replies
Christoph
Level 8

Which type of project are you using? Basic Msi?

0 Kudos

Hi,

I am using InstallScript MSI project.

thanks.

0 Kudos

Hi,

how do call the "Specify destionation location" dialog? Which function do you use?

I'm not 100% familiar with InstallScript (MSI) projects as I'm using 100% of the time Basic MSI installations but when I look into the help, there is a function SdAskDestPath(2) that you can call, and when you click browse within this dialog, the SelectDir function is called where you can specify if the selected directory needs to be created automatically or not.

 

Don't know if this answers your question?

0 Kudos

Hi,

thanks for your response.

I call SdAskDestPath from installscript. And  SdAskDestPath automatically calls SelectDir function  when clicking on the Browse button. As such I have no control as to how to set bCreate parameter that SelectDir takes to either create the dir if it does not exist, or not.

Appreciate any help with this since its important for me to know if the folder existed or was created by InstallShield.

0 Kudos

See the attached screenshot.

Within the installscript view of your project, select from the first, left, drop down menu, dialogsource. Within the right drop down menu, next to it, select the dialog you want to modify.

The function call for the selected dialog will be added to your script and from there, you can modify the code to your own wanted behaviour.

0 Kudos