Cerrar
Close se utiliza para cerrar una instancia de un archivo abierto.
Sintaxis
Cerrar
Devolución
No se devuelven datos.
Ejemplo
Este script abre un archivo (“test.txt”) en la unidad local C y escribe 2 en él:
Function Main
Dim textfile As Object
Set textfile = File.Connect("127.0.0.1")
If textfile.Open("c:\test.txt", GENERIC_WRITE, CREATE_ALWAYS) Then
textfile.WriteLine("Hi, This is a test file")
textfile.WriteLine("It was created using GFI LanGuard scripting")
textfile.Close
End If
End Function