The WriteLine() method writes a string followed by a newline to the text file.
<html> <script language="JScript"> <!-- var myFileSysObj = new ActiveXObject("Scripting.FileSystemObject") var myTextStream = myFileSysObj.OpenTextFile("c:\\temp\\test.txt", 2, true) myTextStream.WriteLine("Hello, World!"); myTextStream.Close(); --> </script> </html>