"Jack Klein" <jackklein@spamcop.net> wrote in message
news:96baj0l7rb6lamfb6d7c63ireaq8b4b6pb@4ax.com...[color=blue]
> On 31 Aug 2004 18:19:09 -0700,
soulsniper@gmail.com (SoulSniper) wrote
>
> By the use of the lame Microsoft-ism "folder" for what everyone else
> in the world called a directory, I'd suggest you ask in
> news:comp.os.ms-windows.win32.programmer or one of Microsoft's
> supports groups in the news:microsoft.public.vc.* family.
>[/color]
FYI, the (fairly) new Mac operating system, OS X, refers to those as
"folders" as well, and even displays icons on the desktop as your typical
office folders. So... not "everyone else in the world" calls them
directories.
As for how to accomplish the task, you're right that methods for listing
directory (or folder) contents is off-topic here.
However, a hint might be given, that you could read the directory list into
a container, select a random index into that container, and then attempt to
use the file referenced by that entry. (But don't forget the obvious...to
include some kind of protection against the file you want no longer being
there!)
-Howard