ASP TextStream.Close Method Last Updated : 03 Mar, 2021 Summarize Comments Improve Suggest changes Share Like Article Like Report The ASP TextStream.Close Method is a predefined method of the TextStream Object which is used to close an opened text file. Syntax: TextStreamObject.Close Example: Below code illustrates the ASP close Method. ASP <% dim gfg,f set gfg=Server.CreateObject("Scripting.FileSystemObject") // creating the file set f=gfg.CreateTextFile("e:\Geeks.txt",true) // Add content f.WriteLine("Hello Geeks") //close the file f.Close Response.write("File is closed") set f=nothing set gfg=nothing %> Output: File is closed Comment More infoAdvertise with us Next Article ASP TextStream.AtEndOfLine Property M manaschhabra2 Follow Improve Article Tags : Websites & Apps ASP-Methods ASP-Basics Similar Reads ASP OpenAsTextStream Method The ASP OpenAsTextStream Method is used to return a TextStream object by opening a specified file. It can be used to perform certain operations on the file. Syntax: FileObject.OpenAsTextStream(mode, format) Parameters: This method has two parameters as mentioned above and described below: mode: It s 2 min read ASP Textstream.Line Property The ASP Textstream.Line Property is a read-only property that can be used to return a current line number in a TextsStream File. Syntax: TextStreamObject.Line Example: Below code returns the current line number: ASP <% dim gfg,f,t set gfg=Server.CreateObject("Scripting.FileSystemObject") set f=g 1 min read ASP TextStream.Column Property The ASP Column Property is used to return the column number of a current character position in a TextStream file.  It is a read-only property. Note: This property is 1 after a newline character is written (even before any other character is written). Syntax: TextStreamObject.Column Example Code: Be 1 min read ASP Read Method The ASP Read Method is used for reading a specified number of characters in a TextStream file. It is a predefined method of the TextStream Object that returns a result as a string. Syntax: TextStreamObject.Read(numchar) Parameter Value: numchar: Required attribute. It contains a numeric value that 1 min read ASP TextStream.AtEndOfLine Property The ASP AtEndOfLine Property is used to return a Boolean value which specifies that whether the file pointer position at the end of the line in a Textstream file. It returns true if the file pointer positioned at the end of the line otherwise it returns false. Note: This property will only work on 1 min read ASP OpenTextFile Method The ASP OpenTextFile Method is used to open a specified file. It returns a TextStream object that can be used to read, write and append contents to the File. It is an in-built function of the FileSystem Object. Syntax: FileSystemObject.OpenTextFile(fname,mode,create,format) Parameter Value: fname: 2 min read Like