Category : Dbase (Clipper, FoxBase, etc) Languages Source Code
Archive   : SERIAL.ZIP
Filename : CODEIT.PRG
Output of file : CODEIT.PRG contained in archive : SERIAL.ZIP
* Author: Dave Irwin
* Copyright (c) 1989 by Software Solutions
*-----------------------------------------------------------------------------
* Created: 5/11/1989 at 10:51
*---------------------------- ALL RIGHTS RESERVED ----------------------------
* Routines used in both SERIAL.PRG and TEST.PRG
*
FUNCTION Serialnum
parameters f_file, f_serial
* you may wish to encrypt f_serial here!
memowrit("SERIAL.TXT", f_serial)
RUN COPY /b &f_file. + Serial.txt &f_file. > NUL
RETURN((ERRORLEVEL() = 0))
FUNCTION Getserial
parameters f_handle, s_length
backtrack = (s_length + 1) * -1
fseek(f_handle, backtrack, 2)
oldstr = freadstr(f_handle, s_length)
* If you encrypted above, be sure to un-encrypt here!
return(oldstr)
PROCEDURE GETID
* READS THE SERIAL NUMBER AND FILE SERVER FROM AN EXE FILE!
PARAMETERS file, mSERIAL, mFS_NAME
mSERIAL = SPACE(15)
mFS_NAME = space(48)
TT_SERIAL = mFS_NAME + mSERIAL
fhandle = fopen(file)
the_number = GETSERIAL(fhandle, LEN(TT_SERIAL))
mFS_NAME = LTRIM(RTRIM(SUBSTR(the_number,1,48)))
mSERIAL = LTRIM(RTRIM(SUBSTR(the_number,49)))
RETURN
*** EOF ***
Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!
This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.
But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/