'=========================================================================== ' Subject: ABC SNIPPET EXTRACTION TO .ZIP Date: 03-15-97 (21:20) ' Author: Xtance Coders Alliance Code: QB, QBasic, PDS ' Origin: harryst@castel.nl Packet: ABC.ABC '=========================================================================== DECLARE SUB Chance2Enter (Lin AS STRING) ' ' New a Xtance Coders Alliance Release by Mr. Snow ' ' This program reads your .abc file that you have typed on the command line. ' and extracts all the sources and zips them after extracting with a ' FILE_ID.DIZ made by this program, nice for board systems ' ' mail - mrsnow@freemail.nl ' ' 03-03-97 ' TYPE ABCFileStructure ' Structures for *.ABC From AS STRING * 31 ' Programmer/Author's name Subject AS STRING * 31 ' Subject/Title of code Origin AS STRING * 31 ' Origin of code, or keywords DateOf AS STRING * 23 ' Date of code release CodeOf AS STRING * 23 ' Code of (QB,QBasic,PDS,ASIC,PB,VB,ASM,TEXT) NumLines AS STRING * 5 ' Number of lines in code Numbytes AS STRING * 9 ' Number of bytes when extracted SaveFile AS STRING * 12 ' Default extraction name END TYPE DIM SHARED ABCFStruct AS ABCFileStructure DIM z AS LONG ON ERROR GOTO Foutje CLS ABCFile$ = COMMAND$ ' Choose an appropriate packet OPEN ABCFile$ FOR BINARY AS #1 DO GET #1, , ABCFStruct.From GET #1, , ABCFStruct.Subject GET #1, , ABCFStruct.Origin GET #1, , ABCFStruct.DateOf GET #1, , ABCFStruct.CodeOf GET #1, , ABCFStruct.NumLines GET #1, , ABCFStruct.Numbytes GET #1, , ABCFStruct.SaveFile COLOR 7, 0: CLS LOCATE 1, 1: COLOR 7, 1 PRINT PRINT "From: "; ABCFStruct.From PRINT "Subject: "; ABCFStruct.Subject PRINT "Origin: "; ABCFStruct.Origin PRINT "DateOf: "; ABCFStruct.DateOf PRINT "CodeOf: "; ABCFStruct.CodeOf PRINT "NumLines: "; ABCFStruct.NumLines PRINT "NumBytes: "; ABCFStruct.Numbytes PRINT "Name: "; ABCFStruct.SaveFile COLOR 7, 0 PRINT PRINT "Extracting file....Adding FILE_ID.DIZ, Ready for Board." PRINT " Swapping.." PRINT STRING$(80, "Ä") OPEN ABCFStruct.SaveFile FOR OUTPUT AS #2 FOR z = 1 TO VAL(ABCFStruct.Numbytes) Copy$ = " " GET #1, , Copy$ Chance2Enter Copy$ IF Copy$ <> CHR$(13) THEN Lijntje$ = Lijntje$ + Copy$ ELSE PRINT #2, Lijntje$ Lijntje$ = "" a = a + 1 IF VAL(ABCFStruct.NumLines) = a THEN EXIT FOR END IF NEXT z a = 0 CLOSE 2 ' Copyied file.. OPEN "FILE_ID.DIZ" FOR OUTPUT AS #2 PRINT #2, " !All Basic Code Source! " PRINT #2, "---------------------------------" PRINT #2, "From: "; ABCFStruct.From + SPACE$(31 - LEN(ABCFStruct.From)) PRINT #2, "Subject: "; ABCFStruct.Subject + SPACE$(31 - LEN(ABCFStruct.Subject)) PRINT #2, "Origin: "; ABCFStruct.Origin + SPACE$(31 - LEN(ABCFStruct.Origin)) PRINT #2, "DateOf: "; ABCFStruct.DateOf + SPACE$(31 - LEN(ABCFStruct.DateOf)) PRINT #2, "CodeOf: "; ABCFStruct.CodeOf + SPACE$(31 - LEN(ABCFStruct.CodeOf)) PRINT #2, "NumLines: "; ABCFStruct.NumLines + SPACE$(31 - LEN(ABCFStruct.NumLines)) PRINT #2, "NumBytes: "; ABCFStruct.Numbytes + SPACE$(31 - LEN(ABCFStruct.Numbytes)) PRINT #2, "------------------------------------" PRINT #2, "tHE wAY tO hEAVEN - Mr. Snow!" CLOSE 2 Punt = INSTR(ABCFStruct.SaveFile, ".") ZipLine$ = "PKZIP " ZipLine$ = ZipLine$ + LEFT$(ABCFStruct.SaveFile, Punt - 1) + ".ZIP " ' Name of The .ZIP File? Or In Your Case ARJ? ZipLine$ = ZipLine$ + ABCFStruct.SaveFile + " FILE_ID.DIZ " ' The Diz file ZipLine$ = ZipLine$ + " -EX -M" ' Stong + Move SHELL ZipLine$ LOOP UNTIL EOF(1) CLOSE 1 END Foutje: CLS CLOSE PRINT "No more files.." KILL COMMAND$ END DEFINT A-Z SUB Chance2Enter (Lin$) IF Lin$ = CHR$(227) THEN Lin$ = CHR$(13) END IF END SUB