home *** CD-ROM | disk | FTP | other *** search
- unit Exmoddb0;
-
- interface
-
- uses
- SysUtils, WinTypes, WinProcs, Messages, Classes, Graphics, Controls,
- Forms, Dialogs, AdModDB, StdCtrls;
-
- type
- TForm1 = class(TForm)
- ListBox1: TListBox;
- Edit1: TEdit;
- ApdModemDBase1: TApdModemDBase;
- procedure FormCreate(Sender: TObject);
- procedure ListBox1Click(Sender: TObject);
- private
- { Private declarations }
- public
- { Public declarations }
- end;
-
- var
- Form1: TForm1;
-
- implementation
-
- {$R *.DFM}
-
- procedure TForm1.FormCreate(Sender: TObject);
- begin
- Listbox1.Items := ApdModemDBase1.Modems;
- end;
-
- procedure TForm1.ListBox1Click(Sender: TObject);
- var
- Info : TModemInfo;
-
- begin
- if (ApdModemDBase1.NumModems <> 0) then
- ApdModemDBase1.GetModem(ListBox1.Items[ListBox1.ItemIndex], Info)
- else
- FillChar(Info, SizeOf(Info), 0);
-
- Edit1.Text := Info.ConfigCmd;
- end;
-
- end.
-
-