Skip to content
⌘ NSIS Forum Archive

select file

8 posts

Yathosho#

select file

is it possible to open a directory and mark a certain file, so one doesn't have to go through a (supposedly big) directory to find the file? most browsers can do this for downloads.
Animaether#
Probably - if you opened the browse dialog yourself 😉

If you specify the filename in the nsDialogs::SelectFileDialog call, it'll pre-select that file in the prompt area.. but the 'explorer view' won't have it selected / scrolled into view. Not sure what you'd need that for unless the user can optionally open the file you'd pre-select but is statistically likely to actually want to open a file that is visually (in the explorer view) close to the one you pre-selected.

off-topic.. you can highlight the explorer view part, start typing the name of a file of interest, and it'll scroll right to that file - no need to scroll through manually 🙂
Yathosho#
Originally Posted by Animaether View Post
If you specify the filename in the nsDialogs::SelectFileDialog call, it'll pre-select that file in the prompt area.. but the 'explorer view' won't have it selected / scrolled into view.
i don't need to open a file, i just want to find it for a user. it's not important though, thought there's a simple way to do this as it's already possible in nsDialogs. maybe i can figure out a different approach.

Originally Posted by Animaether View Post
off-topic.. you can highlight the explorer view part, start typing the name of a file of interest, and it'll scroll right to that file - no need to scroll through manually 🙂
yes, of course. but tell them 😉
Animaether#
Yeah, I'm curious why you're trying to 'find a file for a user' if you already know what it's called and you're not actually using it to open the file or anything.

Unless you slap a name like VisualFileFinder on it and sell it for $2.99 in the App Store, that is.
Yathosho#
Originally Posted by Animaether View Post
Yeah, I'm curious why you're trying to 'find a file for a user' if you already know what it's called and you're not actually using it to open the file or anything
that's because i'm abusing NSIS to create stuff that doesn't install things 🙂

here's a video of what i'm currently working on

@afrowuk: thx
Animaether#
ahhh gotcha - well done 🙂
I wonder why there's a delay in your UI drawing when you change the paths.. we've got pretty much the same thing going on (green/orange/red depending on path validity).. perhaps LockWindow on/off?