searchPathList
981
// JavaScript syntax
put(_player.searchCurrentFolder);
See also
Player
searchPathList
Usage
-- Lingo syntax
_player.searchPathList
// JavaScript syntax
_player.searchPathList;
Description
Player property; a list of paths that Director searches when trying to find linked media such as
digital video, GIFs, bitmaps, or sound files. Read/write.
Each item in the list of paths is a fully qualified pathname as it appears on the current platform
at runtime.
The value of
searchPathList
is a linear list that you can manipulate the same as any other list by
using commands such as
add()
,
addAt()
,
append()
,
deleteAt()
, and
setAt()
. The default
value is an empty list.
URLs should not be used as file references in the search paths.
Adding a large number of paths to
searchPaths
slows searching. Try to minimize the number of
paths in the list.
Note:
This property will function on all subsequent movies after being set. Because the current
movie’s assets have already been loaded, changing the setting will not affect any of these assets.
Example
This statement displays the paths that Director searches when resolving filenames:
-- Lingo syntax
trace(_player.searchPathList)
// JavaScript syntax
trace(_player.searchPathList);
The following statement assigns two folders to
searchPaths
in Windows:
-- Lingo syntax
_player.searchPathList = ["C:\Director\Projects\", "D:\CDROM\Sources\"]
// JavaScript syntax
_player.searchPathList = list("C:\\Director\\Projects\\",
"D:\\CDROM\\Sources\\");
The following statement assigns two folders to
searchPaths
on a Macintosh:
-- Lingo syntax
_player.searchPathList = ["Hard Drive:Director:Projects:", "CDROM:Sources:"]
Summary of Contents for DIRECTOR MX 2004-DIRECTOR SCRIPTING
Page 1: ...DIRECTOR MX 2004 Director Scripting Reference...
Page 48: ...48 Chapter 2 Director Scripting Essentials...
Page 100: ...100 Chapter 4 Debugging Scripts in Director...
Page 118: ...118 Chapter 5 Director Core Objects...
Page 594: ...594 Chapter 12 Methods...
Page 684: ...684 Chapter 14 Properties See also DVD...
Page 702: ...702 Chapter 14 Properties See also face vertices vertices flat...
Page 856: ...856 Chapter 14 Properties JavaScript syntax sprite 15 member member 3 4...
Page 1102: ...1102 Chapter 14 Properties...