Unit TapiDial

Classes

TTapiDial -

Functions

CreateStatusWindow - Creating invisible form
DestroyStatusWindow - if not StatusWindowCreated
Register -
WriteStatus -

Types

TCallDialog
TDialMethod
TDialTone
TStatusWindow

Constants

Variables

buf
callinfo
frmStatus
lbxStatus
LineSt
StatusWindowCreated


Functions


procedure CreateStatusWindow;

Creating invisible form

procedure DestroyStatusWindow;

if not StatusWindowCreated

procedure Register;


procedure WriteStatus(Text:string);


Types


TCallDialog=(None,Win95);
TTapiDial is simple dialing component, which implements dialing through TAPI interface, instead of writing to COM ports directly. This component is based mostly on TAPI Test by Davide Moretti . The reason I'm going through TAPI is that I wrote a dialing component, TTelephon, not so long ago, and it sometimes works, and sometimes doesn't, the reason for that is, I assume, in the new way of accessing COM ports in win95/win32 enviroment, and writing to port is done by API function WriteFile, or Delphi FileWrite,(no WriteComm anymore), well those sometimes do what they are supposed to,and sometimes not.If anyone knows the solution to that please e-mail me. simmiha@filozof.ffzg.hr Anyway, I wrote this little component to finish my Adress application,and it is freeware, and you can do with the code whatever you please. It has 4 "customazible" properties: CallDialog--> Win95(standard TAPI call dilog) --> None (no dialog, just a MessageBox enabling you to hangup) DialTone--> (enable/disable dial tone detection) DialMethod-->(Tone/Pulse) StatusWindow-->(enable/disable StatusWindow which displays current line and dialing state in a small window) And there is, of course TelephonNo--> number to dial It needs TapiH.pas that contains some TAPI declarations, required by component Enjoy it Mihaela Mihaljevich simmiha@filozof.ffzg.hr
TDialMethod=(Tone,Pulse);

TDialTone=Boolean

TStatusWindow=Boolean

Constants


Variables

buf : array[0..1023] of char

callinfo : TLineCallInfo absolute buf

frmStatus : TForm

lbxStatus : TListBox

LineSt : string

StatusWindowCreated : Boolean