Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
************************************************************
* Name: _ListCursor.prg
* Author: justamistere 2004/10/08
* Description: Dumps a cursor's fields in one column.
*
* This can easily be adapted to a .DBF and
* multiple columns, too. Have fun.
*************************************************************
CLOSE DATABASE ALL
OPEN DATABASE "C:\MYDATABASE.DBC"
SELECT * FROM MYTABLE INTO CURSOR ABC
SET SAFETY OFF
SET CONSOLE OFF
WAIT WINDOW AT SROWS()/2, SCOLS()/2 ;
CHR(13) + PADC("Please wait...", 20) + CHR(13) NOWAIT NOCLEAR
SET ALTERNATE TO "XYZ.TXT"
SET ALTERNATE ON
GO TOP
lnI = 1
lnMAXWidth = 0
FOR lnI = 1 TO FCOUNT()
lnMAXWidth = MAX(LEN(FIELD(lnI)), lnMAXWidth)
NEXT
SCAN
?REPLICATE("_", lnMAXWidth)
FOR lnI = 1 TO FCOUNT()
?PADR(FIELD(lnI), lnMAXWidth, ".") + ": "
??EVALUATE(FIELD(lnI))
NEXT
?
ENDSCAN
SET ALTERNATE OFF
SET ALTERNATE TO
SET SAFETY ON
SET CONSOLE ON
WAIT CLEAR
MESSAGEBOX("ALL DONE!")
CLOSE DATABASE ALL