RDD

DbClearIndex()

Close all indexes of the current work area

Syntax

Signature
DbClearIndex() --> NIL

Arguments

None.

Return value

NIL.

Description

DbClearIndex() removes all open orders from the current work area's order list and closes their index files.

Notes

It does not delete the index files from disk.

Example

DbClearIndex.prg
PROCEDURE Main()


   DbUseArea( .T., , "people.dbf", "People" )
   DbCreateIndex( "clear_index.ntx", "NAME", {|| FIELD->NAME } )
   QOut( "Before clear: " + IIF( Empty( OrdName( 1 ) ), "NONE", OrdName( 1 ) ) )
   DbClearIndex()
   QOut( "After clear: " + IIF( Empty( OrdName( 1 ) ), "NONE", OrdName( 1 ) ) )
   DbCloseArea()
   FErase( "clear_index.ntx" )


   RETURN

Output

See also