Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Returns the current state of the processor.
Script Syntax
lReadyState = objXSLProcessor.readyState;
Example
var xslt = new ActiveXObject("Msxml2.XSLTemplate.3.0");
var xslDoc = new ActiveXObject("Msxml2.FreeThreadedDOMDocument.3.0");
var xslProc;
xslDoc.async = false;
xslDoc.load("sample2.xsl");
if (xslDoc.parseError.errorCode != 0) {
var myErr = xslDoc.parseError;
WScript.Echo("You have error " + myErr.reason);
} else {
xslt.stylesheet = xslDoc;
var xmlDoc = new ActiveXObject("Msxml2.DOMDocument.3.0");
xmlDoc.async = false;
xmlDoc.load("books.xml");
if (xmlDoc.parseError.errorCode != 0) {
var myErr = xmlDoc.parseError;
WScript.Echo("You have error " + myErr.reason);
} else {
xslProc = xslt.createProcessor();
WScript.Echo(xslProc.readyState);
xslProc.input = xmlDoc;
WScript.Echo(xslProc.readyState);
}
}
Visual Basic Syntax
lReadyState = objXSLProcessor.readyState
C/C++ Syntax
HRESULT readyState (long* pReadyState);
Parameters
pReadyState
[out, retval]
The state of the current transformation.
Remarks
The readyState
property returns the current state of the processor as follows.
State | Description |
---|---|
READYSTATE_UNINITIALIZED (0) | This is the initial state until all the required properties (in particular, the input property) are set. Calling the transform method at this point returns an error. |
READYSTATE_LOADING (1) | Not used by IXSLProcessor . |
READYSTATE_LOADED (2) | This is the state in which all required properties are set. You can now call the transform method. |
READYSTATE_INTERACTIVE (3) | Thetransform method has been called, but is not finished yet. Not used by IXSLProcessor . |
READYSTATE_COMPLETE (4) | The transformation is finished, but there may still be some output to read if you are reading the output as a string. When you call the reset method or set any property, it reverts to READYSTATE_LOADED. If a required property is cleared, it reverts to READYSTATE_UNINITIALIZED. |
Versioning
Implemented in:
MSXML 3.0, MSXML 6.0