Path: utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!samsung!think!ames!ncar!boulder!ccncsu!longs.LANCE.ColoState.Edu!jn163051 From: jn163051@longs.LANCE.ColoState.Edu (Joel Nevison) Newsgroups: comp.sys.handhelds Subject: 28-S utility programs Message-ID: <3266@ccncsu.ColoState.EDU> Date: 27 Nov 89 17:51:17 GMT Sender: news@ccncsu.ColoState.EDU Reply-To: jn163051@longs.LANCE.ColoState.Edu (Joel Nevison) Organization: Colorado State U. Center for Computer Assisted Engineering Lines: 59 Here are a couple utilities I've worked out PRG -This program purges all type 0 (real number) variables, EQ and PPAR from the current directory. There is a protection feature that prevents the purging of type 0 variables from a directory. To protect a directory store a binary object as the rightmost variable. PRG[6A31] << { EQ PPAR } PURGE VARS LIST-> 1 SWAP FOR X DUP IFERR RCL THEN END TYPE DUP 0 == SWAP 10 == << ABORT >> IFT << PURGE >> << DROP >> IFTE NEXT >> PRDIR -This program dumps to the IR printer; the name of the current directory, the name and contents of every variable in the current directory, the names and contents of subdirectories....etc. PRDIR[6FFF] << "DIR = " IFERR + THEN END PATH DUP SIZE GET ->STR + PR1 DROP VARS LIST-> 1 SWAP FOR X DUP IFERR RCL THEN EVAL "SUB" PRDIR END SWAP PR1 DROP PR1 DROP NEXT "END OF SUBDIR" UP >> This program calls itself when a subdirectory is encountered, it also calls a change directory program named UP. UP was posted recently, but I will include it for completeness. UP[8FCA] << PATH 1 OVER SIZE OVER - SUB #C784h SYSEVAL >> I hope these are useful to someone out there, and if anyone knows a faster or smaller way to do these I am always interested in better ways. Joel Nevison.