home *** CD-ROM | disk | FTP | other *** search
/ Chip 2001 October / Chip_2001-10_cd1.bin / zkuste / delphi / kolekce / d6 / FRCLX.ZIP / DEMO / Unit4.pas < prev    next >
Pascal/Delphi Source File  |  2001-07-30  |  687b  |  40 lines

  1. unit Unit4;
  2.  
  3. interface
  4.  
  5. uses
  6.   SysUtils, Classes, QGraphics, QControls, QForms, QDialogs, QStdCtrls;
  7.  
  8. type
  9.   TForm4 = class(TForm)
  10.     Label1: TLabel;
  11.     Edit1: TEdit;
  12.     Button1: TButton;
  13.     procedure FormClose(Sender: TObject; var Action: TCloseAction);
  14.   private
  15.     { Private declarations }
  16.   public
  17.     { Public declarations }
  18.   end;
  19.  
  20. var
  21.   Form4: TForm4;
  22.  
  23. implementation
  24.  
  25. {$R *.xfm}
  26.  
  27. uses datasets;
  28.  
  29. procedure TForm4.FormClose(Sender: TObject; var Action: TCloseAction);
  30. begin
  31.   with CustomerData.SQLConnection1 do
  32.   begin
  33.     Params.Values['Database'] := Edit1.Text;
  34.     Connected := True;
  35.   end;
  36.   CustomerData.customer.Open;
  37. end;
  38.  
  39. end.
  40.