Revision history for KeyPgLineinputPp


Revision [22006]

Last edited on 2017-11-21 01:11:23 by JeffMarshall [fix page link name case]
Additions:
- ##[[KeyPgLineinput|Line Input]]##
Deletions:
- ##[[KeyPgLineInput|Line Input]]##


Revision [21559]

Edited on 2016-08-15 13:23:56 by DkLwikki [Remove extra empty line]

No Differences

Revision [21497]

Edited on 2016-05-22 12:08:54 by CountingPine [Link to Line Input]
Additions:
- ##[[KeyPgLineInput|Line Input]]##


Revision [20961]

Edited on 2016-03-13 04:19:19 by fxm [Formatting]
Additions:


Revision [20295]

Edited on 2016-02-10 16:02:07 by DkLwikki [Update link format]
Additions:
file number of an file opened for ##[[KeyPgInputfilemode|Input]]##
Reads a line from an open text file (opened for ##[[KeyPgInputfilemode|Input]]## through a bound file number) and stores it in a string variable.
A line of text ends at, but does not include the end of line characters. An end of line character may be the ##LF## character (##[[KeyPgChr|Chr]](10)##) or the ##CRLF## character pair (##[[KeyPgChr|Chr]](13,10)##).
- ##[[KeyPgInputPp|Input #]]##
- ##[[KeyPgOpen|Open]]##
- ##[[KeyPgInputfilemode|Input (file mode)]]##
Deletions:
file number of an file opened for ##[[KeyPgInputfilemode Input]]##
Reads a line from an open text file (opened for ##[[KeyPgInputfilemode Input]]## through a bound file number) and stores it in a string variable.
A line of text ends at, but does not include the end of line characters. An end of line character may be the ##LF## character (##[[KeyPgChr Chr]](10)##) or the ##CRLF## character pair (##[[KeyPgChr Chr]](13,10)##).
- ##[[KeyPgInputPp Input #]]##
- ##[[KeyPgOpen Open]]##
- ##[[KeyPgInputfilemode Input (file mode)]]##


Revision [17002]

Edited on 2014-01-26 14:57:35 by DkLwikki [Remove link to itself]
Deletions:
- ##[[KeyPgLineinputPp Line Input #]]##


Revision [16917]

Edited on 2013-08-18 18:44:52 by CountingPine [New example without error handling, based on KeyPgInputPp]
Additions:
dim s as string
open "myfile.txt" for output as #1
print #1, "Hello, World"
close #1
open "myfile.txt" for input as #1
line input #1, s
close #1
print s
Deletions:
' compile with -lang qb
'$lang: "qb"
Dim Filehandle As Integer
Dim txt As String

On Error Goto HandleErrors

Filehandle = FreeFile
Open "test_text_file.txt" For Input As #filehandle
If LOF(filehandle) > 0 Then
Line Input #filehandle, txt
Else
Goto HandleErrors
End If
Close #filehandle
Print "The first line of test_text_file.txt is:"
Print txt

HandleErrors:
Print "Error."
Resume Next


Revision [13842]

Edited on 2008-10-30 19:18:22 by CountingPine [New example without error handling, based on KeyPgInputPp]
Additions:
- ##[[KeyPgInputfilemode Input (file mode)]]##


Revision [13840]

Edited on 2008-10-30 19:15:33 by CountingPine [New example without error handling, based on KeyPgInputPp]
Additions:
- ##[[KeyPgLineinputPp Line Input #]]##
- ##[[KeyPgOpen Open]]##


Revision [13837]

Edited on 2008-10-30 19:08:46 by CountingPine [New example without error handling, based on KeyPgInputPp]
Additions:
**Line Input** #//file number//, //string_variable//
file number of an file opened for ##[[KeyPgInputfilemode Input]]##
Reads a line from an open text file (opened for ##[[KeyPgInputfilemode Input]]## through a bound file number) and stores it in a string variable.
A line of text ends at, but does not include the end of line characters. An end of line character may be the ##LF## character (##[[KeyPgChr Chr]](10)##) or the ##CRLF## character pair (##[[KeyPgChr Chr]](13,10)##).
Deletions:
**Line Input** #//file number, string_variable//
file number of an open file
Reads a line from an open text file and stores it in a string variable.
A line of text ends at, but does not include the end of line characters. An end of line character may be the ##LF## character (##[[KeyPgChr Chr]]##(10)) or the ##CRLF## character pair (##[[KeyPgChr Chr]]##(13,10)).


Revision [13560]

Edited on 2008-07-21 15:43:38 by JeffMarshall [added #lang or $lang to example]
Additions:
'$lang: "qb"
Filehandle = FreeFile
If LOF(filehandle) > 0 Then
Print "The first line of test_text_file.txt is:"
Print txt
Print "Error."
Deletions:
Filehandle = Freefile
If Lof(filehandle) > 0 Then
print "The first line of test_text_file.txt is:"
print txt
print "Error."


Revision [13222]

The oldest known version of this page was created on 2008-04-25 13:04:06 by AntoniGual [added #lang or $lang to example]
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki



sf.net phatcode