ASP WriteBlankLines メソッド
定義と使用方法
WriteBlankLines メソッドは、指定された数の新しい行を TextStream ファイルに書き込みます。
構文:
TextStreamObject.WriteBlankLines(numlines)
パラメータ | 説明 |
---|---|
numlines | 必須。ファイルに新しい行を書き込むための行数。 |
インスタンス
<% dim fs,f set fs=Server.CreateObject("Scripting.FileSystemObject") set f=fs.CreateTextFile("c:\test.txt",true) f.WriteLine("Hello World!") f.WriteBlankLines(2) f.WriteLine("How are you today?") f.close f = nothing fs = nothing %>
上記のコードを実行した後、test.txtファイルは以下のようになります:
こんにちは、世界! 今日は元気?