bbuchner
Posts: 7
Joined: Fri Jun 15, 2012 10:03 am

User needs to choose the path to a folder

Hello,

In my current installer project the user has to choose the folder of a previously installed program, that has to be shared in the local network. For this I am using a batch file. The problem I have is that I can't manage to build the appropriate dialog. I have tried using the provided tutorial but it doesn't work. What do I have to do?

Regrads,
Bene
mihai.petcu
Posts: 3860
Joined: Thu Aug 05, 2010 8:01 am

Re: User needs to choose the path to a folder

Hi Bene,
The problem I have is that I can't manage to build the appropriate dialog.
Dialogs can be created or edited from the Dialogs page in an Enterprise or above project type. The basic related tutorials are topics of "Using the Dialog Editor".

Can you please give us more specific details about your show stopper? What part of which tutorial is unclear or not working?

All the best,
Mihai
Mihai Petcu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
bbuchner
Posts: 7
Joined: Fri Jun 15, 2012 10:03 am

Re: User needs to choose the path to a folder

Hi Mihai,

Thank you for your answer. Building a dialog in general is not the problem. Here is what I want to do:

- find a certain path on the target system via a browse functionality and set it to a "Simple Edit" field. This path can be differ from target machine to target machine, which is why I want the user to specify the path.
. save the the path as a property of a "Simple Edit" field and pass this path to a batch file as a parameter.

I have found this http://www.advancedinstaller.com/user-g ... older.html tutorial, but it is probably inappropriate for my needs. I have no idea how to do this.

Regards
Bene
mihai.petcu
Posts: 3860
Joined: Thu Aug 05, 2010 8:01 am

Re: User needs to choose the path to a folder

Hi Bene,

Here's Browse for folder thread that debates a similar scenario.

All the best,
Mihai
Mihai Petcu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
bbuchner
Posts: 7
Joined: Fri Jun 15, 2012 10:03 am

Re: User needs to choose the path to a folder

Hi Mihai,

thank you for your reply. I'll try that solution, it sounds like what I want to do. I hope that solves my problem.

Regards,
Bene
bbuchner
Posts: 7
Joined: Fri Jun 15, 2012 10:03 am

Re: User needs to choose the path to a folder

Hi Mihai,

I've followed the instruction as stated in the tutorial. But, once again, I've got a problem. For some reason I get an error message, I've attached a screenshot. Do you know where the problem can be? I hope that I am not bothering you...

Regards,
Bene
Attachments
customDialog.PNG
customDialog.PNG (40.95 KiB) Viewed 7247 times
mihai.petcu
Posts: 3860
Joined: Thu Aug 05, 2010 8:01 am

Re: User needs to choose the path to a folder

Hi Bene,

This is because windows installer tries to resolve that path before sending it to the PathEdit control. So you need to specify a default value (a valid one) for the property of the PathEdit control (see the PathEdit of the "FolderDlg" dialog as example).
By implementing every step of the article you initially found(same one linked from the thread) you shouldn't have gotten this error.

All the best,
Mihai
Mihai Petcu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”