a.guelle
Posts: 97
Joined: Tue May 19, 2015 2:23 pm

[solved] Checking for empty Foder on "FolderDlg"

Mon Jun 08, 2015 10:03 am

Hi,

I wanted to check if the user provided an APPDIR path on the FolderDlg, so I added APPDIR as a condition to display the next dialog. But htis does not work...

Any ideas?
Angelo
Attachments
FolderDlg.PNG
FolderDlg.PNG (41.34KiB)Viewed 5044 times
Last edited by a.guelle on Wed Jun 24, 2015 9:12 am, edited 1 time in total.

Dan
Posts: 4513
Joined: Wed Apr 24, 2013 3:51 pm

Re: Checking for empty Foder on "FolderDlg"

Tue Jun 09, 2015 10:34 am

Hi Angelo,

Please note that the Verify and set the selected folder path - SetTargetPath published event notifies the installer to check and set the selected path. If the path is not valid or the installer doesn't have write access for it, all control events associated with the control are blocked.

Also, the Installation Path Dialog allows you to select a validation method for the selected installation path. The actual validation is performed when pressing [ Next ] button.

As you can see, the user will not be able to proceed with the installation if an empty path is selected or the selected path does not pass the validation. So, can you please tell us why would you like to add an extra check?

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

a.guelle
Posts: 97
Joined: Tue May 19, 2015 2:23 pm

Re: Checking for empty Foder on "FolderDlg"

Tue Jun 09, 2015 11:35 am

Hi Dan,

my Installation Path -> Validation is set to "Use native Windows Installer validation" and the "Verify and set the selected folder Path" event is published. But I am able to provide an empty path and go on with the next dialog... That's something I wanna avoid. I already sent my *.aip file to the support mail address.
Attachments
PublishedEvents.PNG
PublishedEvents.PNG (41.5KiB)Viewed 5014 times
InstallationPath.PNG
InstallationPath.PNG (19.4KiB)Viewed 5014 times

a.guelle
Posts: 97
Joined: Tue May 19, 2015 2:23 pm

Re: Checking for empty Foder on "FolderDlg"

Mon Jun 15, 2015 1:54 pm

Is there a solution for my problem?

Dan
Posts: 4513
Joined: Wed Apr 24, 2013 3:51 pm

Re: Checking for empty Foder on "FolderDlg"

Tue Jun 16, 2015 1:36 pm

Hi,

I assume you deleted the path from the FolderDlg field, right? So, you got an empty path as the installation path?

Please note that the property APPDIR was not actually changed. Its value will be the default one, e.g. C:\Program Files (x86)\Your Company\Your Application\.

You can check this by yourself, using the following test case:
1) set the folder path to an empty string
2) go in the next/previous dialog
3) return to the FolderDlg dialog

Notice that the installation path is filled to the default path.

The path of the installation is actually changed when the Browse... functionality is triggered.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

a.guelle
Posts: 97
Joined: Tue May 19, 2015 2:23 pm

Re: Checking for empty Foder on "FolderDlg"

Tue Jun 16, 2015 3:49 pm

Hi Dan,

you are right, this seems to work.

Thanx,

Angelo

Dan
Posts: 4513
Joined: Wed Apr 24, 2013 3:51 pm

Re: Checking for empty Foder on "FolderDlg"

Wed Jun 17, 2015 1:31 pm

You're always welcome Angelo,

If there is anything else I can help you with, please let me know.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”