home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Windows NT Super Tune-Up Kit
/
PIE-WindowsNTSuperTuneUpKit-1997.iso
/
CONVERTR
/
C2DBASE
/
CDBUTIL.PRC
< prev
next >
Wrap
Text File
|
1985-11-28
|
2KB
|
55 lines
*****************
PROCEDURE RECOUNT
*****************
*THIS PROCEDURE PROVIDES A FAST ALTERNATIVE TO DBASE'S COUNT COMMAND. iT GIVES
*AN UNFILTERED COUNT OF THE NUMBER OF RECORD IN A .DBF FILE. (NORMALLY, YOU CAN
*HIDE CERTAIN RECORDS FROM DBASE BY USING THE 'SET FILTER TO' COMMAND. THIS
*WOULD CHANGE THE RECORD COUNT. THIS PROCEDURE INCLUDES THOSE HIDDEN RECORDS.)
PARAMETERS FILE
RUN CDBUTIL.EXE 2 &FILE
RETURN
******************
PROCEDURE MEMCOUNT
******************
*THIS PROCEDURE IS THE SAME AS RECOUNT, EXCEPT THAT THE RECORD COUNT IS PASSED
*TO A USER SPECIFIED MEMORY VARIABLE.
PARAMETERS FILE,RCOUNT
RUN CDBUTIL.EXE 3 &FILE
*ESTABLISH FULL PATHNAME OF .MEM FILE
TEMP=SUBSTR(FILE,1)
SLASH=AT("\",TEMP)
POSITION=0
DO WHILE SLASH > 0
POSITION=POSITION+SLASH
TEMP=SUBSTR(FILE,1+POSITION)
SLASH=AT("\",TEMP)
ENDDO
MEMFILE=SUBSTR(FILE,1,POSITION)+'RETURN'
RESTORE FROM &MEMFILE ADDITIVE
RCOUNT=VAL(RETPARAM)
*RETPARAM IS ALWAYS RESTORED AS A STRING
RETURN
*****************
PROCEDURE MEMDISP
*****************
*THIS PROCEDURE DISPLAYS THE MEMO FIELD(S) SPECIFIED IN THE VARIABLE RECRANGE
*RECRANGE MUST BE A STRING REPRESENTING A RECORD NUMBER, RECORD RANGE, OR
*STARTING OR ENDING RECORD NUMBER.
PARAMETERS FILE,RECRANGE
RUN CDBUTIL.EXE 5 &FILE &RECRANGE
RETURN
******************
PROCEDURE STRFIND
******************
*THIS PROCEDURE SEARCHES THROUGH RECORDS TO FIND A KEYPHRASE. THE RECORDS
*SEARCHED ARE SPECIFIED IN THE THIRD VARIABLE RECRANGE AND MUST BE A STRING
*OR STRING VARIABLE REPRESENTING THE RECORD OR RECORD RANGE. THE KEYPHRASE
*IS GIVEN IN THE SECOND VARIABLE, AND THE FILE TO BE SEARCHED IS GIVEN IN
*THE FIRST VARIABLE.
PARAMETERS FILE, PHRASE, RECRANGE
RUN CDBUTIL.EXE 6 &FILE &PHRASE &RECRANGE
RETURN