Here's the source for the fdstat program I'm using. Any tips or hints to
improve it would be greatly appreciated.
$COMPILE EXE
$STRING 1
$COM 0
$CPU 80386
$DIM ALL
$OPTIMIZE SIZE
dim BBS(13) as Integer
dim Total as Long
dim OneLine as String
dim CRate as String
dim FileHandle1 as Integer
dim FileHandle2 as Integer
FileHandle1 = FreeFile
FileHandle2 = FreeFile
cls
Print "Running FDSTAT.BAS"
Open "FD.LOG" for input as #1 'FileHandle1
Open "Banner.TXT" for output as #2 'FreeHandle2
While not(EOF(FileHandle1))
Line Input #1, OneLine
CRate = RTrim$(mid$(OneLine, 30, 5))
Select Case CRate
Case "300 b"
incr bbs(0)
Case "1200"
incr bbs(1)
Case "2400"
incr bbs(2)
Case "4800"
incr bbs(3)
Case "7200"
incr bbs(4)
Case "9600"
incr bbs(5)
Case "12000"
incr bbs(6)
Case "14400"
incr bbs(7)
Case "16800"
incr bbs(8)
Case "19200"
incr bbs(9)
Case "21600"
incr bbs(10)
Case "24000"
incr bbs(11)
Case "26400"
incr bbs(12)
Case "28800"
incr bbs(13)
End Select
Wend
Total = bbs(0) + bbs(1) + bbs(2) + bbs(3) + bbs(4) + bbs(5) _
+ bbs(6) + bbs(7) + bbs(8) + bbs(9) + bbs(10) + bbs(11) _
+ bbs(12) + bbs(13)
Print #2, ""
Print #2, ""
Print #2, ""
Print #2, ""
Print #2, " Hang on a Sec, I'm passing control to Zack's
Shack..." Print #2, "" Print #2, " Connections at 300 baud" ;
bbs(0) Print #2, " Connections at 1200 baud" ; bbs(1) Print #2, "
Connections at 2400 baud" ; bbs(2) Print #2, " Connections
at 4800 baud" ; bbs(3) Print #2, " Connections at 7200 baud" ;
bbs(4) Print #2, " Connections at 9600 baud" ; bbs(5) Print #2, "
Connections at 12000 baud" ; bbs(6) Print #2, " Connections
at 14400 baud" ; bbs(7) Print #2, " Connections at 16800 baud" ;
bbs(8) Print #2, " Connections at 19200 baud" ; bbs(9) Print #2, "
Connections at 21600 baud" ; bbs(10) Print #2, " Connections
at 24000 baud" ; bbs(11) Print #2, " Connections at 26400 baud" ;
bbs(12) Print #2, " Connections at 28800 baud" ; bbs(13) Print #2, "
Total " ; Total Close #1 Close FileHandle2
Take Care, Zack Jones
zack@hom.net
--- InterMail 2.29g
---------------
* Origin: Zack's Gotta Point (1:3611/18.10)
|