BBS: Inland Empire Archive Date: 03-25-93 (15:31) Number: 286 From: DIRK THEURER Refer#: NONE To: ALL Recvd: NO Subj: CND-DET routines 1/8 Conf: (2) Quik_Bas
Zack,
Thanks for allowing me to post the following code (8 messages total, all
less than 80 lines).
'--------8<-------------------- snip here -------------------->8--------
'
' CND-DET routines (part 1)
'
' Calling Number Display ("Caller ID" in the US) routines
'
' (c)opyright 1993, Dirk Theurer
'
' This code is placed in the public domain. Use as you see fit. It is NOT
' completely free of 'bugs' but it works in the program it was written for.
'
' Notes: - All of the following code was really a 'hack' to see what could
' be derived from CND (CID). It is not documented very well but I
' think that most of it should be decipherable.
' - There are references to other routines and/or programs. Ignore
' them as best as you can.
' - USE AT YOUR OWN RISK!
' - Enjoy! :-)
'
TYPE CNDType
'
' Data TYPE for CND routines/programs
'
CNDDate AS STRING * 6
CNDTime AS STRING * 6
CNDNumber AS STRING * 13
CNDName AS STRING * 35
CNDCRC AS INTEGER
CNDAttrib AS INTEGER
'
' CNDAttrib
'
' 1 - in-area-code (7 digits)
' 2 - other-area-code (10 digits)
' 3 - in-area-code/DAT ' /in CND.DAT number attributes are
' 4 - other-area-code/DAT ' gained by adding 2 to previous
' ' -area-code attribute
' 5 - in-area-code/DAT/BAD ' /BAD number attributes are gained
' 6 - out-area-code/DAT/BAD ' by adding 2 to previous -area-code
' ' /DAT attribute
' 7 - out of area
' 8 - private
'
' 9 - unknown number format (not 7 or 10 digits but processed anyway)
' 10 - error getting CND data
' (non-fatal - data is processed but not reliable)
'
CNDOther AS INTEGER
'
' CNDOther is used by other programs to determine various attributes
'
' Currently, only CND-CHK uses bit 0 to see if it's already read the last
' entry.
'
CRLF AS STRING * 2
END TYPE
DIM SHARED CND AS CNDType
DECLARE FUNCTION GetCNDNumber% ()
DECLARE FUNCTION GetChar$ ()
CND.CRLF = CHR$(13) + CHR$(10)
'
' Continues...
'
---
* Origin: RAVE * Burnaby, BC (1:153/810)

Books at Amazon:
Back to BASIC: The History, Corruption, and Future of the Language
Hackers: Heroes of the Computer Revolution (including Tiny BASIC)
Go to: The Story of the Math Majors, Bridge Players, Engineers, Chess Wizards, Scientists and Iconoclasts who were the Hero Programmers of the Software Revolution
The Advent of the Algorithm: The Idea that Rules the World
Moths in the Machine: The Power and Perils of Programming
Mastering Visual Basic .NET