TEXTClose and TEXTOpen

Demonstrates how to open and close a text file.

Remarks

This example illustrates how to create a text file, write out three lines of text and then close the text file.

Code

 local integer tfid
 tfid = TEXTOpen( "myfile", "w" )

 CALL TEXTWrite( tfid, "Line 1" )
 CALL TEXTWrite( tfid, "Line 2" )
 CALL TEXTWrite( tfid, "Line 3" )
 CALL TEXTClose( tfid )

© PCI Geomatics Enterprises, Inc.®, 2026. All rights reserved.