TShellTree Problem with path for non folders

Got a problem you cannot solve? Try here.
Treoxx
Posts: 24
Joined: Fri Jan 27, 2006 6:29 am

TShellTree Problem with path for non folders

Postby Treoxx » Wed Feb 01, 2006 8:55 am

Hello,

I like to use PTShellTree for browsing for a license file.
(This file will be later copied to the installation folder)

The options make it possible to show non-folders in the tree list.
The only problem is that when I select a file the path in the TARGETDIR is set to:

c:\\programfiles\\testdir\\licence.txtThe path is always like an folder even when I select non folders.

Is there any solution for this?
(Exept empty the TARGETDIR variabele before the window has opened.)

Thanks!

CandiceJones
Posts: 904
Joined: Thu Dec 22, 2005 7:03 pm
Contact:

Postby CandiceJones » Wed Feb 01, 2006 9:38 am

Hi!

You could just use Parse String and remove the last "\" that way.
Candice Jones
InstallAware
Home of The Next Generation MSI Installer
Get your free copy today - http://www.installaware.com/

Treoxx
Posts: 24
Joined: Fri Jan 27, 2006 6:29 am

Postby Treoxx » Wed Feb 01, 2006 9:57 am

yes, that is an option I've tried.

But it looks stupid for the user at the time a file is choosen, and there are some other troubles.

Like this:

Choose file:

D:\\testdir\\test.txt\\

next
back

D:\\testdir\\test.txt

next
back
Choose other file! and than it happends:

D:\\testdir\\theotherfilecomeshere.txt\\test.txt



Yust tried again: Above doen't have anything to do with the parse string, it is always happening, the second try to select a file.

jimo
Posts: 342
Joined: Fri Aug 19, 2005 10:59 am
Location: Atlanta, GA
Contact:

Postby jimo » Wed Feb 01, 2006 10:10 am

You may want to try the "File Dialog" plugin to return the file name.

Available here:mdPlugins

Treoxx
Posts: 24
Joined: Fri Jan 27, 2006 6:29 am

Postby Treoxx » Wed Feb 01, 2006 10:23 am

I've tried the plugin and it is a workable option.

The problem is just:

The user has to choose three different things:

InstallationDir
DatabaseDir
Licensefile

I'd like to see that all dialogs work on the same way to keep it simple, fast and clean.

InstallationDir and DatabaseDir are not a problem with the PTShellTree, the licensefile is another story.

MichaelNesmith
Posts: 3452
Joined: Thu Dec 22, 2005 7:17 pm
Contact:

Postby MichaelNesmith » Wed Feb 01, 2006 1:46 pm

Maybe you can use the PTShellList to select the file? After all, that control is specifically designed to display files.
Michael Nesmith
InstallAware
Home of The Next Generation MSI Installer
Get your free copy today - http://www.installaware.com/

Treoxx
Posts: 24
Joined: Fri Jan 27, 2006 6:29 am

Postby Treoxx » Thu Feb 02, 2006 4:30 am

I've tried the PTShellList but I'm having the same problems.
The slash is always there even after a file selection.

And the problem I've described in the post in this tread at Wed Feb 01, 2006 2:57 pm.

MichaelNesmith
Posts: 3452
Joined: Thu Dec 22, 2005 7:17 pm
Contact:

Postby MichaelNesmith » Thu Feb 02, 2006 7:48 am

Hi!

I built an example project for you...its called "File Selector" and contains Explorer controls.

I have attached the built EXE and the sources of the project. It works fine as far as I can tell...please take a look!

File Attached:

File Selector.zip
Michael Nesmith

InstallAware

Home of The Next Generation MSI Installer

Get your free copy today - http://www.installaware.com/

Treoxx
Posts: 24
Joined: Fri Jan 27, 2006 6:29 am

Postby Treoxx » Fri Feb 03, 2006 4:05 am

Michael,

That is the exact same way I did to get the problem out of the way :)

The problem was that I liked to use an edit box with it, so the user can fill in the location of the file without browsing, so I had to use the variable TARGETDIR. (To let show the selected path in the edit box.)

I've changed your version to my first solution, with the problem with the slashes.

Try to select a file, next - back - select another file.
And have a look at the PATH.

Many thanks for the support by the way!

File Attached:

File Selector.zip

MichaelNesmith
Posts: 3452
Joined: Thu Dec 22, 2005 7:17 pm
Contact:

Postby MichaelNesmith » Fri Feb 03, 2006 8:05 am

Ah, I see! This is because you are setting the "receives value" field to "installation folder", which is causing the file path to be modified like a folder path.
Michael Nesmith

InstallAware

Home of The Next Generation MSI Installer

Get your free copy today - http://www.installaware.com/

Treoxx
Posts: 24
Joined: Fri Jan 27, 2006 6:29 am

Postby Treoxx » Fri Feb 03, 2006 9:16 am

MichaelNesmith wrote:Ah, I see! This is because you are setting the "receives value" field to "installation folder", which is causing the file path to be modified like a folder path.


Thats true,

But if I don't do that the edit box is not interactive with the PTShellList.
So I can never show an good filepath in an interactive editbox.

MichaelNesmith
Posts: 3452
Joined: Thu Dec 22, 2005 7:17 pm
Contact:

Postby MichaelNesmith » Fri Feb 03, 2006 10:21 am

Don't worry - we're addressing this control interactivity issue very soon. Having to fall back on TARGETDIR for everything is getting quite inconvenient, so we will resolve this!
Michael Nesmith

InstallAware

Home of The Next Generation MSI Installer

Get your free copy today - http://www.installaware.com/


Return to “Technical Support”

Who is online

Users browsing this forum: No registered users and 162 guests