Presenting successive file names in 'Open'

Rob Cozens rcozens at
Wed Dec 1 13:28:57 EST 2004

Hi Graham,

>I want a user to see the contents of a series of text files, all in 
>the same folder. Let's say the files are called A01,A02... G99 or 
>something like that. The sequence of operations is -
>1. The user is offered a normal 'open' dialog to select a file, 
>initially navigating to the folder in question and picking A01 to 
>2. The user looks at the file, does some action and disposes of it.
>3. The user usually then wishes to look at the next file in the 
>alphabetical sequence (A02 in my example, but it might be any text 
>string). Clearly she/he can navigate to this name by:
>  a) remembering the name of the last file looked at;
>b) scrolling down to the file below the last file looked at in the 
>normal 'open' dialog
>If there are a lot of files, this scrolling becomes tedious on most 
>OSs (e.g in OSX the OS 'open' dialog doesn't hilite the last file 
>read, nor does it scroll down to it), so I would prefer to propose 
>the name of the next file in the sequence in the 'open' dialog for 
>the user to accept or reject.
>What would be the best way to do this? So far I've only thought of 
>traversing the folder somehow before the user starts work, and 
>putting all the file names in a list field for the user to pick 
>from. Seems kind of overkill, though.
>All thoughts gratefully received.

If you were content to simply have the user pick among all files in 
the folder last visited, you could simply set the defaultFolder to 
the folder containing the last file selected after each selection.

Placing a list of the files in a field may seem like overkill; but it 
allows additional options.  Example:
With SDB's folder archive stack the user can deselect/select 
individual files by clicking on them and folders by ctrl-clicking on 
any file in a folder.  Deselected items are colored gray; selected 
items inherit the field's textColor.  You could use the same 
technique to mark which files on the list have already been visited.

Rob Cozens
CCW, Serendipity Software Company

"And I, which was two fooles, do so grow three;
Who are a little wise, the best fooles bee."

from "The Triple Foole" by John Donne (1572-1631)

More information about the use-livecode mailing list