writeln Method (Windows Scripting - JScript)
Sends strings to the script debugger, followed by a newline character.
Syntax
Debug.writeln([str1 [, str2 [, ... [, strN]]]])
Arguments
- str1, str2, ... , strN
Optional. Strings to send to the script debugger.
Remarks
The writeln method sends strings, followed by a newline character, to the Immediate window of the Microsoft Script Debugger at run time. If the script is not being debugged, the writeln method has no effect.
The writeln method is almost identical to the write method. The only difference is that the write method does not send a newline character after sending the strings.
This example uses the writeln method to display the value of the variable in the Immediate window of the Microsoft Script Debugger.
Note
To run this example, you must have a script debugger installed and the script must run in debug mode.
Internet Explorer 8 includes the Microsoft JScript debugger. If you are using an earlier version of Internet Explorer, see How to: Enable and Start Script Debugging from Internet Explorer.
var counter = 42;
Debug.writeln("The value of counter is " + counter);
Requirements
Applies To: Debug Object (Windows Scripting - JScript)
Change History
Date |
History |
Reason |
---|---|---|
March 2009 |
Modified note about script debugger. |
Content bug fix. |