461
You can also alter the value of this property by using the
addChild
command.
Example
The following statement sets the parent property of the model named Tire. Its parent is set to the
model named Car.
member("Scene").model("Tire").parent = \
member("Scene").model("Car")
See also
child
,
addChild
parseString()
Syntax
parserObject
.parseString(
stringToParse
)
Description
Function; used to parse an XML document that is already fully available to the Director movie.
The first parameter is the variable containing the parser object, and the second is the string
containing the XML data. The return value is
<VOID>
if the operation succeeds, or an error code
number string if it fails. Failure is usually due to a problem with the XML syntax or structure.
Once the operation is complete, the parser object contains the parsed XML data.
To parse XML at a URL, use
parseURL()
.
Example
This statement parses the XML data in the text cast member XMLtext. Once the operation is
complete, the variable
gParserObject
will contain the parsed XML data.
errorCode = gParserObject.parseString(member("XMLtext"))
See also
getError() (XML)
,
parseURL()
parseURL()
Syntax
parserObject
.parseURL(
URLstring
{,#handlerToCallOnCompletion} {,
objectContainingHandler}
)
Description
Function; parses an XML document that resides at an external Internet location. The first
parameter is the parser object containing an instance of the XML Parser Xtra, and the second is
the actual URL at which the XML data resides.
This function returns immediately, so the entire URL may not yet be parsed. It is important to
use the
doneParsing()
function in conjunction with
parseURL()
to determine when the
parsing operation is complete.
Since this operation is asynchronous, meaning it may take some time, you can use optional
parameters to call a specific handler when the operation completes. The optional third parameter
is the name of a handler that is to be executed once the URL is fully parsed; the optional fourth
parameter is the name of the script object containing that handler. If the fourth parameter is not
passed in, the handler name in parameter three is assumed to be a movie handler.
Содержание DIRECTOR MX-LINGO DICTIONARY
Страница 1: ...Lingo Dictionary Macromedia Director MX...
Страница 756: ...Index 756...