DIAdem Help

Method: Close for TextStream

  • Updated2024-09-12
  • 1 minute(s) read

Method: Close for TextStream

Closes an open TextStream file.

Object.Close
ObjectTextStream
Object with this method

The following example creates a text file, writes a text into this file, and then closes the file:

Sub CreateMyTxtFile(sFile,sText)
  Dim fso, oMyFile
  Set fso = CreateObject("Scripting.FileSystemObject")
  Set oMyFile = fso.CreateTextFile(sFile, True)
  Call oMyFile.WriteLine(sText)
  Call oMyFile.Close
End Sub

Log in to get a better experience