Reputation:
(sorry, not exactly a coding question)
Say I want to install something to the directory C:\pony but the folder 'pony' does not exist, how can I get InstallShield to inform the user that the folder 'pony' does not exist and ask the user if he or she wants to create the directory.
What happens now is the directory is automatically created.
Is this simply a limitation of the install shield I'm using (2008 Express)?
Upvotes: 0
Views: 1184
Reputation: 10687
Some InstallScript code would do it:
if (ExistsDir(szPath) == NOTEXISTS) then
if (AskYesNo("The directory does not exist. Would you like Setup to create it?", YES) == NO) then
abort;
else
CreateDir(szPath);
endif;
endif;
Upvotes: 2
Reputation: 13577
I don't know of a built-in way to do this. You may need to write some custom code (either InstallScript or MSI custom action, depending on what kind of project you are using) to check whether the directory exists and prompt the user.
Upvotes: 0