psf
Posts: 43
Joined: Wed Jun 04, 2014 11:00 am

installer crash after enter invalid path and cancel

In some cases, one of our install packages crashes if the user , when presented with the standard 'Select Installation Folder' page, enters an invalid path (e.g. "abcde" - something which leads to install error 1314 "the specified path 'abcde' is unavailable") then presses the Cancel button. - a dialogbox is presented , text contains "This installer database contains the logic and data required to install <our product name> has stopped working".

It does not happen all the time, and if you run the install using msiexec specifying the msi file, it never seems to happen.

Does anybody have any suggestions on how to prevent this crash?
Dan
Posts: 4513
Joined: Wed Apr 24, 2013 3:51 pm

Re: installer crash after enter invalid path and cancel

Hello,

Can you please attach a sample project that replicates this behaviour? Also, please give us a detailed test case scenario.

The validation for the installation path is done by the Windows Installer. The actual validation is performed when pressing [ Next ] button. For details, please check the Installation Path Dialog article.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
psf
Posts: 43
Joined: Wed Jun 04, 2014 11:00 am

Re: installer crash after enter invalid path and cancel

The Cancel button the FolderDlg has an associated event 'Display a specific child dialog', the CancelDlg.
And if the path in the editbox is valid, that is what appears when you press cancel.
But if the path in the edit box is invalid, then it seems to wait a while, then report "the specified path 'xyz' is invalid", as if it 's performing validation on the path when you press the cancel button - i.e. the same validation as if you had pressed the 'Next' button. Pressing the Back button also seems to perform validation, even though only the 'Next' button has the 'verify and set the selected folder path' event associated with it.
Which doesn't seem right to me.
psf
Posts: 43
Joined: Wed Jun 04, 2014 11:00 am

Re: installer crash after enter invalid path and cancel

It is easy to create a repro of the validation issue . I just created a new enterprise installer project using AI 12.3.1, saved it , ran it, got to the Select Installation Folder, entered a bad path, and pressed back or cancel - you can see that it performs validation of the path, even though no such validation event is associated with those buttons .

It is harder to repro the crash we sometimes experience, but the above issue is consistently reproducible.
psf
Posts: 43
Joined: Wed Jun 04, 2014 11:00 am

Re: installer crash after enter invalid path and cancel

I have attached my trivial sample .aip file which illustrates the back/cancel button validation of folder path issue described in my earlier post.
Attachments
Your Application.aip
(10.59 KiB) Downloaded 403 times
Daniel
Posts: 8238
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: installer crash after enter invalid path and cancel

Hello,

We tested the scenario and replicated the behavior. I'm not so sure why this happens though. This seems to be an Advanced Installer issue, thank you for bringing it to our attention. A fix will be available in a future version of Advanced Installer. We will notify you as soon as the fix will be out.

Until then, as a workaround you can enable our Enhanced User Interface feature.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
Daniel
Posts: 8238
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: installer crash after enter invalid path and cancel

Hello,

We further investigated this behavior and we found that it is caused by Windows Installer. At install time Windows Installer validates the path you entered in the PathEdit control each time you want to move focus from the PathEdit control. This is the default Windows Installer behavior.

As a workaround, in order to avoid this behavior you can simply delete the existing PathEdit control from "FolderDlg" dialog and add in place an Edit control using "APPDIR" for its associated property.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
psf
Posts: 43
Joined: Wed Jun 04, 2014 11:00 am

Re: installer crash after enter invalid path and cancel

Thanks for the information and suggestion.
Regards
Paul
Daniel
Posts: 8238
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: installer crash after enter invalid path and cancel

You're always welcome Paul.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”