unit TestMain;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, FIBQuery, pFIBQuery, FIBDatabase, pFIBDatabase, StdCtrls,
  ExtCtrls, Buttons, frxClass;

type
  TForm1 = class(TForm)
    pFIBDbArc: TpFIBDatabase;
    pFIBTrnArc: TpFIBTransaction;
    QueryArc: TpFIBQuery;
    trnReadArc: TpFIBTransaction;
    Panel1: TPanel;
    Button1: TButton;
    Edit1: TEdit;
    SpeedButton1: TSpeedButton;
    procedure Button1Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

uses ArcViewer;

{$R *.dfm}

procedure TForm1.Button1Click(Sender: TObject);
var
  ArcViewerForm: TArcViewerForm;
begin

  pFIBDbArc.DBName := Edit1.Text;
  pFIBDbArc.Connected := true;

  ArcViewerForm := TArcViewerForm.Create(self);
  ArcViewerForm.Readonly := SpeedButton1.Down;
  ArcViewerForm.db := pFIBDbArc;
  ArcViewerForm.fname := ChangeFileExt( Application.ExeName, '.avc');

  ArcViewerForm.Show;

  ArcViewerForm.Init;

end;

end.
