In addition to the good suggestions already made, if you want to get really fancy:

This script uses BuddyAPI, but check out  the available arguments and adapt it to your 
taste.


Here some info from my code lib:

-------------------------------------------------------------
on openFolder theDir, theArgs
  --  /n = new window
  --  /e = explorer mode (split)

  aSep = ""
  if (theArgs.char[theArgs.length] <> ",") then aSep = ","

  theString = "EXPLORER.EXE" && theArgs & aSep && theDir

  baRunProgram(theString, "normal", false )
end

--Example Call:
--
--theDir = "C:\Documents and Settings\Bertil Flink\Desktop\BBC\"
--theArgs = "/n,/e,"
--openFolder theDir, theArgs

-----------------------------------------------------------------------

--Below, is an explanation of Explorer's command-line syntax originally
written by Greg Wolking [ZDNet]. Some examples contain spaces in order to
format properly on this page, so you may need to remove them if you copy and
paste.
--
--EXPLORER [/E, | /N,]pathspec[,/ROOT,rootspec] [,/SELECT,filespec]
--
--Note that _only_ commas, not spaces, separate all switches and arguments.
Therefore, it is not necessary to quote file or path names that include
"reserved" characters. Command line is not case-sensitive, and order of
arguments is not important.
--
--The pathspec and rootspec arguments must point to a folder. The filespec
argument can point to either a folder or a file.
--
--/E = Opens a new explorer view window.
--
--/N = Opens a new folder view window. Otherwise, if a folder view of the
specified folder is already open, simply activates that window. /E overrides
/N.
--
--pathspec = target path to open. Appears as the window caption in folder
view. In explorer view, tree in left hand pane is open to the specified
folder. This argument is ignored if the /SELECT,filespec option is used.
--
--/ROOT,rootspec = User cannot navigate any higher in the directory tree
than rootspec. When this option is used, pathspec or filespec must be
relative to rootspec.
--
--/SELECT,filespec = opens desired view with specified object (file or
folder) selected. If used, pathspec is ignored (it defaults to the parent
folder of filespec).
--
--Note that when /ROOT,rootspec is used, then both pathspec and filespec
must be relative to rootspec, regardless of the order in which the
parameters are specified. For example,:
--
--EXPLORER /E,SYSTEM,/ROOT, D:\WINDOWS,/SELECT,SYSTEM\SHELL32.DLL
--
--EXPLORER /E,/SELECT,SYSTEM\SHELL32.DLL,/ROOT, D:\WINDOWS
--
--both do exactly the same thing: Open an Explorer view with the tree
limited to D:\WINDOWS or below, the left pane opened to the
D:\WINDOWS\SYSTEM folder, and the file SHELL32.DLL selected in the right
pane. Changing /E, to /N, would open a new folder view of D:\WINDOWS\SYSTEM
with SHELL32.DLL selected, and the user could navigate no higher in the tree
than D:\WINDOWS.
--
--However,
--
--EXPLORER /ROOT,D:\WINDOWS,/SELECT, D:\WINDOWS\SYSTEM\SHELL32.DLL
--
--would fail because "D:\WINDOWS\SYSTEM\SHELL32.DLL" is an explicit path,
not a relative path.




-- 
Bertil Flink
Creative Media




----- Original Message ----- 
From: "Todd Culley" <[EMAIL PROTECTED]>
Subject: <lingo-l> dumb question - opening a folder


> Hello List,
> 
> How do you open a folder for browsing with director? I know how to open a
> file in Director using fileIO, filextra, fileXtra4, and buddyAPI but I don't
> see any commands to open just the folder.
> 
> There are functions to return a list of folders or files but I just want to
> open the folder and let the user browse on their own using the Explorer
> window.
> 
> Using DirectorMX, WindowsXP Pro
> 
> tia, todd

[To remove yourself from this list, or to change to digest mode, go to 
http://www.penworks.com/lingo-l.cgi  To post messages to the list, email [EMAIL 
PROTECTED]  (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping 
with programming Lingo.  Thanks!]

Reply via email to