Difference between revisions of "EOF()"

From Lianjapedia
Jump to: navigation, search
 
 
(3 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 
==Purpose==
 
==Purpose==
 
Function to check if the record pointer is at the end of file
 
Function to check if the record pointer is at the end of file
 
  
 
==Syntax==
 
==Syntax==
 
EOF([<workarea | alias>])
 
EOF([<workarea | alias>])
 
  
 
==See Also==
 
==See Also==
 
[[BOF()]], [[CURSYNCNUM()]], [[DELETE]], [[FOUND()]], [[PACK]], [[RECALL]], [[RECNO()]], [[ROWNUM()]], [[SET DELETED]], [[SYNCNUM()]]
 
[[BOF()]], [[CURSYNCNUM()]], [[DELETE]], [[FOUND()]], [[PACK]], [[RECALL]], [[RECNO()]], [[ROWNUM()]], [[SET DELETED]], [[SYNCNUM()]]
 
  
 
==Description==
 
==Description==
 
The EOF() function returns .T. when the last logical record of the table is passed.  If the optional <workarea | alias> is specified, then the function will operate in the required location.  The EOF() function is set to .T. if  SEEK, FIND, LOCATE or CONTINUE operations are not successful.
 
The EOF() function returns .T. when the last logical record of the table is passed.  If the optional <workarea | alias> is specified, then the function will operate in the required location.  The EOF() function is set to .T. if  SEEK, FIND, LOCATE or CONTINUE operations are not successful.
 
  
 
==Example==
 
==Example==
Line 27: Line 23:
 
</code>
 
</code>
  
 
==Products==
 
Recital Server, Recital
 
 
[[Category:Documentation]]
 
[[Category:Documentation]]
 
[[Category:Functions]]
 
[[Category:Functions]]
[[Category:Table Basics]]
+
[[Category:Cursor Functions]]
[[Category:Table Basics Functions]]
+

Latest revision as of 10:50, 4 February 2013

Purpose

Function to check if the record pointer is at the end of file

Syntax

EOF([<workarea | alias>])

See Also

BOF(), CURSYNCNUM(), DELETE, FOUND(), PACK, RECALL, RECNO(), ROWNUM(), SET DELETED, SYNCNUM()

Description

The EOF() function returns .T. when the last logical record of the table is passed. If the optional <workarea | alias> is specified, then the function will operate in the required location. The EOF() function is set to .T. if SEEK, FIND, LOCATE or CONTINUE operations are not successful.

Example

use catalogue
do while not eof()
    m_file=lower(trim(file) + "." + filetype)
    if not file("&m_file")
        delete
    endif
    skip
enddo