unit U_con_Membros;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls, Grids, DBGrids, DBCtrls, Buttons;

type
  TfrmCons_Membros = class(TForm)
    Label2: TLabel;
    Label3: TLabel;
    Label4: TLabel;
    Edit_cod_ini: TEdit;
    Edit_cod_final: TEdit;
    Edit_cons_nome: TEdit;
    DBGrid1: TDBGrid;
    Button2: TButton;
    Label1: TLabel;
    EditDatIni: TEdit;
    Label6: TLabel;
    EditNomeRel: TEdit;
    Label7: TLabel;
    EditEndereco: TEdit;
    EditCargo: TEdit;
    EditEscola: TEdit;
    Label5: TLabel;
    Label8: TLabel;
    Label9: TLabel;
    EditCelula: TEdit;
    Button1: TButton;
    BitBtn1: TBitBtn;
    DBLookupComboBox1: TDBLookupComboBox;
    DBLookupComboBox2: TDBLookupComboBox;
    DBLookupComboBox3: TDBLookupComboBox;
    BitBtn2: TBitBtn;
    BitBtn3: TBitBtn;
    BitBtn4: TBitBtn;
    procedure FormCreate(Sender: TObject);
    procedure Button2Click(Sender: TObject);
    procedure Button3Click(Sender: TObject);
    procedure Edit_cons_nomeChange(Sender: TObject);
    procedure Edit_cod_iniChange(Sender: TObject);
    procedure Edit_cod_finalChange(Sender: TObject);
    procedure FormActivate(Sender: TObject);
    procedure FormKeyPress(Sender: TObject; var Key: Char);
    procedure BitBtn1Click(Sender: TObject);
    procedure DBLookupComboBox1Click(Sender: TObject);
    procedure DBLookupComboBox2Click(Sender: TObject);
    procedure DBLookupComboBox3Click(Sender: TObject);
    procedure BitBtn2Click(Sender: TObject);
    procedure BitBtn3Click(Sender: TObject);
    procedure BitBtn4Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  frmCons_Membros: TfrmCons_Membros;

implementation

uses UDM_dados, U_relConMembros, U_Membros, U_configuracao;

{$R *.dfm}

procedure TfrmCons_Membros.FormCreate(Sender: TObject);
begin
dm_dados.Cons_Membro.Active := True ;
end;

procedure TfrmCons_Membros.Button2Click(Sender: TObject);
begin
frmRelConsMembros.QRLabel1.Caption := frmCons_Membros.EditNomeRel.Text ;
frmRelConsMembros.QuickRep1.Preview;
end;

procedure TfrmCons_Membros.Button3Click(Sender: TObject);
begin
frmConfSist.Button3.Visible:= false;
frmCons_Membros.Hide ;
frmConfSist.Show ;
frmConfSist.TabSheet2.SetFocus  ;

end;

procedure TfrmCons_Membros.Edit_cons_nomeChange(Sender: TObject);
begin
       dm_dados.Cons_Membro.close;
       dm_dados.Cons_Membro.ParamByName('codini').AsInteger :=StrToInt (Edit_cod_ini.text);
       dm_dados.Cons_Membro.ParamByName('codfinal').AsInteger :=StrToInt (Edit_cod_final.text);
       dm_dados.Cons_Membro.ParamByName('nome').AsString := '%'+ Edit_cons_nome.text+'%';
       dm_dados.Cons_Membro.ParamByName('dtnasc').AsString := '%'+ EditDatIni.text+'%';
       dm_dados.Cons_Membro.ParamByName('endereco').AsString := '%'+ EditEndereco.text+'%';

       dm_dados.Cons_Membro.ParamByName('cargo').AsString := '%'+ EditCargo.text+'%';
       dm_dados.Cons_Membro.ParamByName('escola').AsString := '%'+ EditEscola.text+'%';
       dm_dados.Cons_Membro.ParamByName('celula').AsString := '%'+ EditCelula.text+'%';
       dm_dados.Cons_Membro.Open;

end;

procedure TfrmCons_Membros.Edit_cod_iniChange(Sender: TObject);
begin
       dm_dados.Cons_Membro.close;
       dm_dados.Cons_Membro.ParamByName('codini').AsInteger :=StrToInt (Edit_cod_ini.text);
       dm_dados.Cons_Membro.ParamByName('codfinal').AsInteger :=StrToInt (Edit_cod_final.text);
       dm_dados.Cons_Membro.ParamByName('nome').AsString := '%'+ Edit_cons_nome.text+'%';
       dm_dados.Cons_Membro.ParamByName('dtnasc').AsString := '%'+ EditDatIni.text+'%';
       dm_dados.Cons_Membro.ParamByName('endereco').AsString := '%'+ EditEndereco.text+'%';

       dm_dados.Cons_Membro.ParamByName('cargo').AsString := '%'+ EditCargo.text+'%';
       dm_dados.Cons_Membro.ParamByName('escola').AsString := '%'+ EditEscola.text+'%';
       dm_dados.Cons_Membro.ParamByName('celula').AsString := '%'+ EditCelula.text+'%';

       dm_dados.Cons_Membro.Open;

end;

procedure TfrmCons_Membros.Edit_cod_finalChange(Sender: TObject);
begin
       dm_dados.Cons_Membro.close;
       dm_dados.Cons_Membro.ParamByName('codini').AsInteger :=StrToInt (Edit_cod_ini.text);
       dm_dados.Cons_Membro.ParamByName('codfinal').AsInteger :=StrToInt (Edit_cod_final.text);
       dm_dados.Cons_Membro.ParamByName('nome').AsString := '%'+ Edit_cons_nome.text+'%';
       dm_dados.Cons_Membro.ParamByName('dtnasc').AsString := '%'+ EditDatIni.text+'%';
       dm_dados.Cons_Membro.ParamByName('endereco').AsString := '%'+ EditEndereco.text+'%';

       dm_dados.Cons_Membro.ParamByName('cargo').AsString := '%'+ EditCargo.text+'%';
       dm_dados.Cons_Membro.ParamByName('escola').AsString := '%'+ EditEscola.text+'%';
       dm_dados.Cons_Membro.ParamByName('celula').AsString := '%'+ EditCelula.text+'%';

       dm_dados.Cons_Membro.Open;

end;

procedure TfrmCons_Membros.FormActivate(Sender: TObject);
begin
EditDatIni.Text := '';
frmCons_Membros.Caption := frmConfSist.DBEdit2.Text ;
frmCons_Membros.EditNomeRel.Text := frmConfSist.DBEdit5.Text ;

{frmCons_Membros.Label3.Caption  := frmConfSist.DBEdit7.Text ;
frmCons_Membros.Label1.Caption := frmConfSist.DBEdit12.Text ;
frmCons_Membros.Label7.Caption := frmConfSist.DBEdit8.Text ;}

{frmCons_Membros.Label8.Caption := frmConfSist.DBEdit14.Text ;
frmCons_Membros.Label9.Caption := frmConfSist.DBEdit15.Text ;
frmCons_Membros.Label5.Caption := frmConfSist.DBEdit16.Text ;}

frmCons_Membros.DBGrid1.Columns[1].Title.Caption := frmConfSist.DBEdit7.Text  ;
frmCons_Membros.DBGrid1.Columns[2].Title.Caption := frmConfSist.DBEdit8.Text  ;
frmCons_Membros.DBGrid1.Columns[3].Title.Caption := frmConfSist.DBEdit9.Text  ;
frmCons_Membros.DBGrid1.Columns[4].Title.Caption := frmConfSist.DBEdit10.Text  ;
frmCons_Membros.DBGrid1.Columns[5].Title.Caption := frmConfSist.DBEdit11.Text  ;
frmCons_Membros.DBGrid1.Columns[6].Title.Caption := frmConfSist.DBEdit12.Text  ;
frmCons_Membros.DBGrid1.Columns[7].Title.Caption := frmConfSist.DBEdit13.Text  ;
frmCons_Membros.DBGrid1.Columns[8].Title.Caption := frmConfSist.DBEdit14.Text  ;
frmCons_Membros.DBGrid1.Columns[9].Title.Caption := frmConfSist.DBEdit15.Text  ;
frmCons_Membros.DBGrid1.Columns[10].Title.Caption := frmConfSist.DBEdit16.Text  ;
frmCons_Membros.DBGrid1.Columns[11].Title.Caption := frmConfSist.DBEdit17.Text  ;
frmCons_Membros.DBGrid1.Columns[12].Title.Caption := frmConfSist.DBEdit18.Text  ;
frmCons_Membros.DBGrid1.Columns[13].Title.Caption := frmConfSist.DBEdit6.Text  ;
frmCons_Membros.DBGrid1.Columns[14].Title.Caption := frmConfSist.DBEdit19.Text  ;
frmRelConsMembros.QRLabel2.Caption := frmConfSist.DBEdit4.Text ;

if frmConfSist.checkbox2.Checked = true then
begin
frmRelConsMembros.QRLabel3.Caption := frmConfSist.DBEdit7.Text;
frmRelConsMembros.QRLabel3.Enabled := True ;
frmRelConsMembros.QRDBText2.Enabled := true ;
end;



if frmConfSist.checkbox3.Checked = true then
begin
frmRelConsMembros.QRLabel3.Caption := frmConfSist.DBEdit8.Text;
frmRelConsMembros.QRLabel3.Enabled := True ;
frmRelConsMembros.QRDBText4.Enabled := true ;
end  ;



if frmConfSist.checkbox4.Checked = true then
begin
frmRelConsMembros.QRLabel3.Caption := frmConfSist.DBEdit9.Text ;
frmRelConsMembros.QRLabel3.Enabled := true;
frmRelConsMembros.QRDBText4.Enabled := true ;
end;



if frmConfSist.checkbox5.Checked = true then
begin
frmRelConsMembros.QRLabel3.Caption := frmConfSist.DBEdit10.Text ;
frmRelConsMembros.QRLabel3.Enabled := true;
frmRelConsMembros.QRDBText5.Enabled := true ;
end;



if frmConfSist.checkbox6.Checked = true then
begin
frmRelConsMembros.QRLabel3.Caption := frmConfSist.DBEdit11.Text  ;
frmRelConsMembros.QRLabel3.Enabled := true;
frmRelConsMembros.QRDBText6.Enabled := true ;
end;



if frmConfSist.checkbox7.Checked = true then
begin
frmRelConsMembros.QRLabel3.Caption := frmConfSist.DBEdit12.Text  ;
frmRelConsMembros.QRLabel3.Enabled := true;
frmRelConsMembros.QRDBText7.Enabled := true ;
end;



if frmConfSist.checkbox8.Checked = true then
begin
frmRelConsMembros.QRLabel3.Caption := frmConfSist.DBEdit13.Text  ;
frmRelConsMembros.QRLabel3.Enabled := true;
frmRelConsMembros.QRDBText8.Enabled := true ;
end;



if frmConfSist.checkbox9.Checked = true then
begin
frmRelConsMembros.QRLabel3.Caption := frmConfSist.DBEdit14.Text ;
frmRelConsMembros.QRLabel3.Enabled := true;
frmRelConsMembros.QRDBText9.Enabled := true ;
end;



if frmConfSist.checkbox10.Checked = true then
begin
frmRelConsMembros.QRLabel3.Caption := frmConfSist.DBEdit15.Text  ;
frmRelConsMembros.QRLabel3.Enabled := true;
frmRelConsMembros.QRDBText10.Enabled := true ;
end;



if frmConfSist.checkbox11.Checked = true then
begin
frmRelConsMembros.QRLabel3.Caption := frmConfSist.DBEdit16.Text  ;
frmRelConsMembros.QRLabel3.Enabled := true;
frmRelConsMembros.QRDBText11.Enabled := true ;
end;



if frmConfSist.checkbox12.Checked = true then
begin
frmRelConsMembros.QRLabel3.Caption := frmConfSist.DBEdit18.Text  ;
frmRelConsMembros.QRLabel3.Enabled := true;
frmRelConsMembros.QRDBText12.Enabled := true ;
end;



if frmConfSist.checkbox13.Checked = true then
begin
frmRelConsMembros.QRLabel3.Caption := frmConfSist.DBEdit19.Text  ;
frmRelConsMembros.QRLabel3.Enabled := true;
frmRelConsMembros.QRDBText13.Enabled := true ;
end;



if frmConfSist.checkbox14.Checked = true then
begin
frmRelConsMembros.QRLabel3.Caption := frmConfSist.DBEdit20.Text ;
frmRelConsMembros.QRLabel3.Enabled := true;
frmRelConsMembros.QRDBText14.Enabled := true ;
end;



if frmConfSist.checkbox16.Checked = true then
begin
frmRelConsMembros.QRLabel4.Caption := frmConfSist.DBEdit7.Text  ;
frmRelConsMembros.QRLabel4.Enabled := true;
frmRelConsMembros.QRDBText16.Enabled := true ;
end;



if frmConfSist.checkbox17.Checked = true then
begin
frmRelConsMembros.QRLabel4.Caption := frmConfSist.DBEdit8.Text ;
frmRelConsMembros.QRLabel4.Enabled := true;
frmRelConsMembros.QRDBText17.Enabled := true ;
end;



if frmConfSist.checkbox18.Checked = true then
begin
frmRelConsMembros.QRLabel4.Caption := frmConfSist.DBEdit9.Text  ;
frmRelConsMembros.QRLabel4.Enabled := true;
frmRelConsMembros.QRDBText18.Enabled := true ;
end;



if frmConfSist.checkbox19.Checked = true then
begin
frmRelConsMembros.QRLabel4.Caption := frmConfSist.DBEdit10.Text  ;
frmRelConsMembros.QRLabel4.Enabled := true;
frmRelConsMembros.QRDBText19.Enabled := true ;
end;



if frmConfSist.checkbox20.Checked = true then
begin
frmRelConsMembros.QRLabel4.Caption := frmConfSist.DBEdit11.Text;
frmRelConsMembros.QRLabel4.Enabled := true;
frmRelConsMembros.QRDBText20.Enabled := true ;
end;



if frmConfSist.checkbox21.Checked = true then
begin
frmRelConsMembros.QRLabel4.Caption := frmConfSist.DBEdit12.Text  ;
frmRelConsMembros.QRLabel4.Enabled := true;
frmRelConsMembros.QRDBText21.Enabled := true ;
end;



if frmConfSist.checkbox22.Checked = true then
begin
frmRelConsMembros.QRLabel4.Caption := frmConfSist.DBEdit13.Text  ;
frmRelConsMembros.QRLabel4.Enabled := true;
frmRelConsMembros.QRDBText22.Enabled := true ;
end;



if frmConfSist.checkbox23.Checked = true then
begin
frmRelConsMembros.QRLabel4.Caption := frmConfSist.DBEdit14.Text ;
frmRelConsMembros.QRLabel4.Enabled := true;
frmRelConsMembros.QRDBText23.Enabled := true ;
end;



if frmConfSist.checkbox24.Checked = true then
begin
frmRelConsMembros.QRLabel4.Caption := frmConfSist.DBEdit15.Text  ;
frmRelConsMembros.QRLabel4.Enabled := true;
frmRelConsMembros.QRDBText24.Enabled := true ;
end;



if frmConfSist.checkbox25.Checked = true then
begin
frmRelConsMembros.QRLabel4.Caption := frmConfSist.DBEdit16.Text ;
frmRelConsMembros.QRLabel4.Enabled := true;
frmRelConsMembros.QRDBText25.Enabled := true ;
end;



if frmConfSist.checkbox26.Checked = true then
begin
frmRelConsMembros.QRLabel4.Caption := frmConfSist.DBEdit18.Text  ;
frmRelConsMembros.QRLabel4.Enabled := true;
frmRelConsMembros.QRDBText26.Enabled := true ;
end;



if frmConfSist.checkbox27.Checked = true then
begin
frmRelConsMembros.QRLabel4.Caption := frmConfSist.DBEdit19.Text  ;
frmRelConsMembros.QRLabel4.Enabled := true;
frmRelConsMembros.QRDBText27.Enabled := true ;
end;



if frmConfSist.checkbox28.Checked = true then
begin
frmRelConsMembros.QRLabel4.Caption := frmConfSist.DBEdit20.Text ;
frmRelConsMembros.QRLabel4.Enabled := true;
frmRelConsMembros.QRDBText28.Enabled := true ;
end;



if frmConfSist.checkbox29.Checked = true then
begin
frmRelConsMembros.QRDBText29.Enabled := true ;
end;


if frmConfSist.checkbox30.Checked = true then
begin
frmRelConsMembros.QRLabel5.Caption := frmConfSist.DBEdit7.Text;
frmRelConsMembros.QRDBText30.Enabled := true ;
end;



if frmConfSist.checkbox31.Checked = true then
begin
frmRelConsMembros.QRLabel5.Caption := frmConfSist.DBEdit8.Text  ;
frmRelConsMembros.QRLabel5.Enabled := true;
frmRelConsMembros.QRDBText31.Enabled := true ;
end;



if frmConfSist.checkbox32.Checked = true then
begin
frmRelConsMembros.QRLabel5.Caption := frmConfSist.DBEdit9.Text ;
frmRelConsMembros.QRLabel5.Enabled := true;
frmRelConsMembros.QRDBText32.Enabled := true ;
end;



if frmConfSist.checkbox33.Checked = true then
begin
frmRelConsMembros.QRLabel5.Caption := frmConfSist.DBEdit10.Text ;
frmRelConsMembros.QRLabel5.Enabled := true;
frmRelConsMembros.QRDBText33.Enabled := true ;
end;



if frmConfSist.checkbox34.Checked = true then
begin
frmRelConsMembros.QRLabel5.Caption := frmConfSist.DBEdit11.Text ;
frmRelConsMembros.QRLabel5.Enabled := true;
frmRelConsMembros.QRDBText34.Enabled := true ;
end;



if frmConfSist.checkbox35.Checked = true then
begin
frmRelConsMembros.QRLabel5.Caption := frmConfSist.DBEdit12.Text ;
frmRelConsMembros.QRLabel5.Enabled := true;
frmRelConsMembros.QRDBText35.Enabled := true ;
end;



if frmConfSist.checkbox36.Checked = true then
begin
frmRelConsMembros.QRLabel5.Caption := frmConfSist.DBEdit13.Text  ;
frmRelConsMembros.QRLabel5.Enabled := true;
frmRelConsMembros.QRDBText36.Enabled := true ;
end;



if frmConfSist.checkbox37.Checked = true then
begin
frmRelConsMembros.QRLabel5.Caption := frmConfSist.DBEdit14.Text  ;
frmRelConsMembros.QRLabel5.Enabled := true;
frmRelConsMembros.QRDBText37.Enabled := true ;
end;



if frmConfSist.checkbox38.Checked = true then
begin
frmRelConsMembros.QRLabel5.Caption := frmConfSist.DBEdit15.Text ;
frmRelConsMembros.QRLabel5.Enabled := true;
frmRelConsMembros.QRDBText38.Enabled := true ;
end;



if frmConfSist.checkbox39.Checked = true then
begin
frmRelConsMembros.QRLabel5.Caption := frmConfSist.DBEdit16.Text ;
frmRelConsMembros.QRLabel5.Enabled := true;
frmRelConsMembros.QRDBText39.Enabled := true ;
end;



if frmConfSist.checkbox40.Checked = true then
begin
frmRelConsMembros.QRLabel5.Caption := frmConfSist.DBEdit18.Text ;
frmRelConsMembros.QRLabel5.Enabled := true;
frmRelConsMembros.QRDBText40.Enabled := true ;
end;



if frmConfSist.checkbox41.Checked = true then
begin
frmRelConsMembros.QRLabel5.Caption := frmConfSist.DBEdit18.Text ;
frmRelConsMembros.QRLabel5.Enabled := true;
frmRelConsMembros.QRDBText41.Enabled := true ;
end;



if frmConfSist.checkbox42.Checked = true then
begin
frmRelConsMembros.QRLabel5.Caption := frmConfSist.DBEdit19.Text ;
frmRelConsMembros.QRLabel5.Enabled := true;
frmRelConsMembros.QRDBText42.Enabled := true ;
end;



if frmConfSist.checkbox43.Checked = true then
begin
frmRelConsMembros.QRDBText43.Enabled := true ;
end;


if frmConfSist.checkbox44.Checked = true then
begin
frmRelConsMembros.QRLabel6.Caption := frmConfSist.DBEdit7.Text   ;
frmRelConsMembros.QRLabel6.Enabled := true;
frmRelConsMembros.QRDBText44.Enabled := true ;
end;



if frmConfSist.checkbox45.Checked = true then
begin
frmRelConsMembros.QRLabel6.Caption := frmConfSist.DBEdit8.Text   ;
frmRelConsMembros.QRLabel6.Enabled := true;
frmRelConsMembros.QRDBText45.Enabled := true ;
end;



if frmConfSist.checkbox46.Checked = true then
begin
frmRelConsMembros.QRLabel6.Caption := frmConfSist.DBEdit9.Text  ;
frmRelConsMembros.QRLabel6.Enabled := true;
frmRelConsMembros.QRDBText46.Enabled := true ;
end;



if frmConfSist.checkbox47.Checked = true then
begin
frmRelConsMembros.QRLabel6.Caption := frmConfSist.DBEdit10.Text  ;
frmRelConsMembros.QRLabel6.Enabled := true;
frmRelConsMembros.QRDBText47.Enabled := true ;
end;



if frmConfSist.checkbox48.Checked = true then
begin
frmRelConsMembros.QRLabel6.Caption := frmConfSist.DBEdit11.Text  ;
frmRelConsMembros.QRLabel6.Enabled := true;
frmRelConsMembros.QRDBText48.Enabled := true ;
end;



if frmConfSist.checkbox49.Checked = true then
begin
frmRelConsMembros.QRLabel6.Caption := frmConfSist.DBEdit12.Text ;
frmRelConsMembros.QRLabel6.Enabled := true;
frmRelConsMembros.QRDBText49.Enabled := true ;
end ;



if frmConfSist.checkbox50.Checked = true then
begin
frmRelConsMembros.QRLabel6.Caption := frmConfSist.DBEdit13.Text  ;
frmRelConsMembros.QRLabel6.Enabled := true;
frmRelConsMembros.QRDBText50.Enabled := true ;
end;



if frmConfSist.checkbox51.Checked = true then
begin
frmRelConsMembros.QRLabel6.Caption := frmConfSist.DBEdit14.Text  ;
frmRelConsMembros.QRLabel6.Enabled := true;
frmRelConsMembros.QRDBText51.Enabled := true ;
end  ;



if frmConfSist.checkbox52.Checked = true then
begin
frmRelConsMembros.QRLabel6.Caption := frmConfSist.DBEdit15.Text  ;
frmRelConsMembros.QRDBText52.Enabled := true ;
end;



if frmConfSist.checkbox53.Checked = true then
begin
frmRelConsMembros.QRLabel6.Caption := frmConfSist.DBEdit7.Text  ;
frmRelConsMembros.QRLabel6.Enabled := true;
frmRelConsMembros.QRDBText53.Enabled := true ;
end;



if frmConfSist.checkbox54.Checked = true then
begin
frmRelConsMembros.QRLabel6.Caption := frmConfSist.DBEdit18.Text ;
frmRelConsMembros.QRLabel6.Enabled := true;
frmRelConsMembros.QRDBText54.Enabled := true ;
end;



if frmConfSist.checkbox55.Checked = true then
begin
frmRelConsMembros.QRDBText55.Enabled := true ;
end;


if frmConfSist.checkbox56.Checked = true then
begin
frmRelConsMembros.QRLabel6.Caption := frmConfSist.DBEdit19.Text  ;
frmRelConsMembros.QRLabel6.Enabled := true;
frmRelConsMembros.QRDBText56.Enabled := true ;
end;



if frmConfSist.checkbox57.Checked = true then
begin
frmRelConsMembros.QRDBText57.Enabled := true ;
end;


if frmConfSist.checkbox58.Checked = true then
begin
frmRelConsMembros.QRLabel7.Caption := frmConfSist.DBEdit7.Text   ;
frmRelConsMembros.QRLabel7.Enabled := true;
frmRelConsMembros.QRDBText58.Enabled := true ;
end;



if frmConfSist.checkbox59.Checked = true then
begin
frmRelConsMembros.QRLabel7.Caption := frmConfSist.DBEdit8.Text   ;
frmRelConsMembros.QRLabel7.Enabled := true;
frmRelConsMembros.QRDBText59.Enabled := true ;
end;



if frmConfSist.checkbox60.Checked = true then
begin
frmRelConsMembros.QRLabel7.Caption := frmConfSist.DBEdit9.Text   ;
frmRelConsMembros.QRLabel7.Enabled := true;
frmRelConsMembros.QRDBText60.Enabled := true ;
end;



if frmConfSist.checkbox61.Checked = true then
begin
frmRelConsMembros.QRLabel7.Caption := frmConfSist.DBEdit10.Text   ;
frmRelConsMembros.QRLabel7.Enabled := true;
frmRelConsMembros.QRDBText61.Enabled := true ;
end;



if frmConfSist.checkbox62.Checked = true then
begin
frmRelConsMembros.QRLabel7.Caption := frmConfSist.DBEdit11.Text   ;
frmRelConsMembros.QRLabel7.Enabled := true;
frmRelConsMembros.QRDBText62.Enabled := true ;
end ;



if frmConfSist.checkbox63.Checked = true then
begin
frmRelConsMembros.QRLabel7.Caption := frmConfSist.DBEdit12.Text   ;
frmRelConsMembros.QRLabel7.Enabled := true;
frmRelConsMembros.QRDBText63.Enabled := true ;
end;



if frmConfSist.checkbox64.Checked = true then
begin
frmRelConsMembros.QRLabel7.Caption := frmConfSist.DBEdit13.Text   ;
frmRelConsMembros.QRLabel7.Enabled := true;
frmRelConsMembros.QRDBText64.Enabled := true ;
end;



if frmConfSist.checkbox65.Checked = true then
begin
frmRelConsMembros.QRLabel7.Caption := frmConfSist.DBEdit14.Text   ;
frmRelConsMembros.QRLabel7.Enabled := true;
frmRelConsMembros.QRDBText65.Enabled := true ;
end;



if frmConfSist.checkbox66.Checked = true then
begin
frmRelConsMembros.QRLabel7.Caption := frmConfSist.DBEdit15.Text   ;
frmRelConsMembros.QRLabel7.Enabled := true;
frmRelConsMembros.QRDBText66.Enabled := true ;
end ;



if frmConfSist.checkbox67.Checked = true then
begin
frmRelConsMembros.QRLabel7.Caption := frmConfSist.DBEdit16.Text   ;
frmRelConsMembros.QRLabel7.Enabled := true;
frmRelConsMembros.QRDBText67.Enabled := true ;
end;



if frmConfSist.checkbox68.Checked = true then
begin
frmRelConsMembros.QRLabel7.Caption := frmConfSist.DBEdit18.Text   ;
frmRelConsMembros.QRLabel7.Enabled := true;
frmRelConsMembros.QRDBText68.Enabled := true ;
end;



if frmConfSist.checkbox69.Checked = true then
begin
frmRelConsMembros.QRDBText69.Enabled := true ;
end;


if frmConfSist.checkbox70.Checked = true then
begin
frmRelConsMembros.QRLabel7.Caption := frmConfSist.DBEdit19.Text   ;
frmRelConsMembros.QRLabel7.Enabled  := true;
frmRelConsMembros.QRDBText70.Enabled := true ;
end;



if frmConfSist.checkbox71.Checked = true then
begin
frmRelConsMembros.QRDBText71.Enabled := true ;
end;


if frmConfSist.checkbox72.Checked = true then
begin
frmRelConsMembros.QRLabel8.Caption := frmConfSist.DBEdit7.Text ;
frmRelConsMembros.QRLabel8.Enabled := true;
frmRelConsMembros.QRDBText72.Enabled := true ;
end;



if frmConfSist.checkbox73.Checked = true then
begin
frmRelConsMembros.QRLabel8.Caption := frmConfSist.DBEdit8.Text ;
frmRelConsMembros.QRLabel8.Enabled := true;
frmRelConsMembros.QRDBText73.Enabled := true ;
end;



if frmConfSist.checkbox74.Checked = true then
begin
frmRelConsMembros.QRLabel8.Caption := frmConfSist.DBEdit9.Text ;
frmRelConsMembros.QRLabel8.Enabled := true;
frmRelConsMembros.QRDBText74.Enabled := true ;
end;



if frmConfSist.checkbox75.Checked = true then
begin
frmRelConsMembros.QRLabel8.Caption := frmConfSist.DBEdit10.Text ;
frmRelConsMembros.QRLabel8.Enabled := true;
frmRelConsMembros.QRDBText75.Enabled := true ;
end;



if frmConfSist.CheckBox76.Checked = true then
begin
frmRelConsMembros.QRLabel8.Caption := frmConfSist.DBEdit11.Text ;
frmRelConsMembros.QRLabel8.Enabled := true;
frmRelConsMembros.QRDBText76.Enabled := true ;
end;



if frmConfSist.CheckBox77.Checked = true then
begin
frmRelConsMembros.QRLabel8.Caption := frmConfSist.DBEdit12.Text ;
frmRelConsMembros.QRLabel8.Enabled := true;
frmRelConsMembros.QRDBText77.Enabled := true ;
end;



if frmConfSist.CheckBox78.Checked = true then
begin
frmRelConsMembros.QRLabel8.Caption := frmConfSist.DBEdit13.Text ;
frmRelConsMembros.QRLabel8.Enabled := true;
frmRelConsMembros.QRDBText78.Enabled := true ;
end;



if frmConfSist.CheckBox79.Checked = true then
begin
frmRelConsMembros.QRLabel8.Caption := frmConfSist.DBEdit14.Text ;
frmRelConsMembros.QRLabel8.Enabled := true;
frmRelConsMembros.QRDBText79.Enabled := true ;
end;



if frmConfSist.CheckBox80.Checked = true then
begin
frmRelConsMembros.QRLabel8.Caption := frmConfSist.DBEdit15.Text ;
frmRelConsMembros.QRLabel8.Enabled := true;
frmRelConsMembros.QRDBText80.Enabled := true ;
end;



if frmConfSist.CheckBox81.Checked = true then
begin
frmRelConsMembros.QRLabel8.Caption := frmConfSist.DBEdit16.Text ;
frmRelConsMembros.QRLabel8.Enabled := true;
frmRelConsMembros.QRDBText81.Enabled := true ;
end;



if frmConfSist.CheckBox82.Checked = true then
begin
frmRelConsMembros.QRLabel8.Caption := frmConfSist.DBEdit18.Text ;
frmRelConsMembros.QRLabel8.Enabled := true;
frmRelConsMembros.QRDBText82.Enabled := true ;
end;



if frmConfSist.CheckBox83.Checked = true then
begin
frmRelConsMembros.QRDBText83.Enabled := true ;
end;


if frmConfSist.CheckBox84.Checked = true then
begin
frmRelConsMembros.QRLabel8.Caption := frmConfSist.DBEdit19.Text ;
frmRelConsMembros.QRLabel8.Enabled := true;
frmRelConsMembros.QRDBText84.Enabled := true ;
end;

if frmConfSist.CheckBox1.Checked = false then
begin
frmRelConsMembros.QRDBText1.enabled := false;
end;
if frmConfSist.CheckBox2.Checked = false then
begin
frmRelConsMembros.QRDBText2.enabled := false;
end;
if frmConfSist.CheckBox3.Checked = false then
begin
frmRelConsMembros.QRDBText3.enabled := false;
end;
if frmConfSist.CheckBox4.Checked = false then
begin
frmRelConsMembros.QRDBText4.enabled := false;
end;
if frmConfSist.CheckBox5.Checked = false then
begin
frmRelConsMembros.QRDBText5.enabled := false;
end;
if frmConfSist.CheckBox6.Checked = false then
begin
frmRelConsMembros.QRDBText6.enabled := false;
end;
if frmConfSist.CheckBox7.Checked = false then
begin
frmRelConsMembros.QRDBText7.enabled := false;
end;
if frmConfSist.CheckBox8.Checked = false then
begin
frmRelConsMembros.QRDBText8.enabled := false;
end;
if frmConfSist.CheckBox9.Checked = false then
begin
frmRelConsMembros.QRDBText9.enabled := false;
end;
if frmConfSist.CheckBox10.Checked = false then
begin
frmRelConsMembros.QRDBText10.enabled := false;
end;
if frmConfSist.CheckBox11.Checked = false then
begin
frmRelConsMembros.QRDBText11.enabled := false;
end;
if frmConfSist.CheckBox12.Checked = false then
begin
frmRelConsMembros.QRDBText12.enabled := false;
end;
if frmConfSist.CheckBox13.Checked = false then
begin
frmRelConsMembros.QRDBText13.enabled := false;
end;
if frmConfSist.CheckBox14.Checked = false then
begin
frmRelConsMembros.QRDBText14.enabled := false;
end;



if frmConfSist.CheckBox15.Checked = false  then
begin
frmRelConsMembros.QRDBText15.enabled := false;
end;
if frmConfSist.CheckBox16.Checked = false  then
begin
frmRelConsMembros.QRDBText16.enabled := false;
end;
if frmConfSist.CheckBox17.Checked = false  then
begin
frmRelConsMembros.QRDBText17.enabled := false;
end;
if frmConfSist.CheckBox18.Checked = false  then
begin
frmRelConsMembros.QRDBText18.enabled := false;
end;
if frmConfSist.CheckBox19.Checked = false  then
begin
frmRelConsMembros.QRDBText19.enabled := false;
end;
if frmConfSist.CheckBox20.Checked = false  then
begin
frmRelConsMembros.QRDBText20.enabled := false;
end;
if frmConfSist.CheckBox21.Checked = false  then
begin
frmRelConsMembros.QRDBText21.enabled := false;
end;
if frmConfSist.CheckBox22.Checked = false  then
begin
frmRelConsMembros.QRDBText22.enabled := false;
end;
if frmConfSist.CheckBox23.Checked = false  then
begin
frmRelConsMembros.QRDBText23.enabled := false;
end;
if frmConfSist.CheckBox24.Checked = false  then
begin
frmRelConsMembros.QRDBText24.enabled := false;
end;
if frmConfSist.CheckBox25.Checked = false  then
begin
frmRelConsMembros.QRDBText25.enabled := false;
end;
if frmConfSist.CheckBox26.Checked = false  then
begin
frmRelConsMembros.QRDBText26.enabled := false;
end;
if frmConfSist.CheckBox27.Checked = false  then
begin
frmRelConsMembros.QRDBText27.enabled := false;
end;
if frmConfSist.CheckBox28.Checked = false  then
begin
frmRelConsMembros.QRDBText28.enabled := false;
end;



if frmConfSist.CheckBox29.Checked = false  then
begin
frmRelConsMembros.QRDBText29.enabled := false;
end;
if frmConfSist.CheckBox30.Checked = false  then
begin
frmRelConsMembros.QRDBText30.enabled := false;
end;
if frmConfSist.CheckBox31.Checked = false  then
begin
frmRelConsMembros.QRDBText31.enabled := false;
end;
if frmConfSist.CheckBox32.Checked = false  then
begin
frmRelConsMembros.QRDBText32.enabled := false;
end;
if frmConfSist.CheckBox33.Checked = false  then
begin
frmRelConsMembros.QRDBText33.enabled := false;
end;
if frmConfSist.CheckBox34.Checked = false  then
begin
frmRelConsMembros.QRDBText34.enabled := false;
end;
if frmConfSist.CheckBox35.Checked = false  then
begin
frmRelConsMembros.QRDBText35.enabled := false;
end;
if frmConfSist.CheckBox36.Checked = false  then
begin
frmRelConsMembros.QRDBText36.enabled := false;
end;
if frmConfSist.CheckBox37.Checked = false  then
begin
frmRelConsMembros.QRDBText37.enabled := false;
end;
if frmConfSist.CheckBox38.Checked = false  then
begin
frmRelConsMembros.QRDBText38.enabled := false;
end;
if frmConfSist.CheckBox39.Checked = false  then
begin
frmRelConsMembros.QRDBText39.enabled := false;
end;
if frmConfSist.CheckBox40.Checked = false  then
begin
frmRelConsMembros.QRDBText40.enabled := false;
end;
if frmConfSist.CheckBox41.Checked = false  then
begin
frmRelConsMembros.QRDBText41.enabled := false;
end;
if frmConfSist.CheckBox42.Checked = false  then
begin
frmRelConsMembros.QRDBText42.enabled := false;
end;

if frmConfSist.CheckBox43.Checked = false then
begin
frmRelConsMembros.QRDBText43.enabled := false;
end;
if frmConfSist.CheckBox44.Checked = false then
begin
frmRelConsMembros.QRDBText44.enabled := false;
end;
if frmConfSist.CheckBox45.Checked = false then
begin
frmRelConsMembros.QRDBText45.enabled := false;
end;
if frmConfSist.CheckBox46.Checked = false then
begin
frmRelConsMembros.QRDBText46.enabled := false;
end;
if frmConfSist.CheckBox47.Checked = false then
begin
frmRelConsMembros.QRDBText47.enabled := false;
end;
if frmConfSist.CheckBox48.Checked = false then
begin
frmRelConsMembros.QRDBText48.enabled := false;
end;
if frmConfSist.CheckBox49.Checked = false then
begin
frmRelConsMembros.QRDBText49.enabled := false;
end;
if frmConfSist.CheckBox50.Checked = false then
begin
frmRelConsMembros.QRDBText50.enabled := false;
end;
if frmConfSist.CheckBox51.Checked = false then
begin
frmRelConsMembros.QRDBText51.enabled := false;
end;
if frmConfSist.CheckBox52.Checked = false then
begin
frmRelConsMembros.QRDBText52.enabled := false;
end;
if frmConfSist.CheckBox53.Checked = false then
begin
frmRelConsMembros.QRDBText53.enabled := false;
end;
if frmConfSist.CheckBox54.Checked = false then
begin
frmRelConsMembros.QRDBText54.enabled := false;
end;
if frmConfSist.CheckBox55.Checked = false then
begin
frmRelConsMembros.QRDBText55.enabled := false;
end;
if frmConfSist.CheckBox56.Checked = false then
begin
frmRelConsMembros.QRDBText56.enabled := false;
end;

if frmConfSist.CheckBox57.Checked = false  then
begin
frmRelConsMembros.QRDBText57.enabled := false;
end;
if frmConfSist.CheckBox58.Checked = false  then
begin
frmRelConsMembros.QRDBText58.enabled := false;
end;
if frmConfSist.CheckBox59.Checked = false  then
begin
frmRelConsMembros.QRDBText59.enabled := false;
end;
if frmConfSist.CheckBox60.Checked = false  then
begin
frmRelConsMembros.QRDBText60.enabled := false;
end;
if frmConfSist.CheckBox61.Checked = false  then
begin
frmRelConsMembros.QRDBText61.enabled := false;
end;
if frmConfSist.CheckBox62.Checked = false  then
begin
frmRelConsMembros.QRDBText62.enabled := false;
end;
if frmConfSist.CheckBox63.Checked = false  then
begin
frmRelConsMembros.QRDBText63.enabled := false;
end;
if frmConfSist.CheckBox64.Checked = false  then
begin
frmRelConsMembros.QRDBText64.enabled := false;
end;
if frmConfSist.CheckBox65.Checked = false  then
begin
frmRelConsMembros.QRDBText65.enabled := false;
end;
if frmConfSist.CheckBox66.Checked = false  then
begin
frmRelConsMembros.QRDBText66.enabled := false;
end;
if frmConfSist.CheckBox67.Checked = false  then
begin
frmRelConsMembros.QRDBText67.enabled := false;
end;
if frmConfSist.CheckBox68.Checked = false  then
begin
frmRelConsMembros.QRDBText68.enabled := false;
end;
if frmConfSist.CheckBox69.Checked = false  then
begin
frmRelConsMembros.QRDBText69.enabled := false;
end;
if frmConfSist.CheckBox70.Checked = false  then
begin
frmRelConsMembros.QRDBText70.enabled := false;
end;

if frmConfSist.CheckBox71.Checked = false  then
begin
frmRelConsMembros.QRDBText71.enabled := false;
end;
if frmConfSist.CheckBox72.Checked = false  then
begin
frmRelConsMembros.QRDBText72.enabled := false;
end;
if frmConfSist.CheckBox73.Checked = false  then
begin
frmRelConsMembros.QRDBText73.enabled := false;
end;
if frmConfSist.CheckBox74.Checked = false  then
begin
frmRelConsMembros.QRDBText74.enabled := false;
end;
if frmConfSist.CheckBox75.Checked = false  then
begin
frmRelConsMembros.QRDBText75.enabled := false;
end;
if frmConfSist.CheckBox76.Checked = false  then
begin
frmRelConsMembros.QRDBText76.enabled := false;
end;
if frmConfSist.CheckBox77.Checked = false  then
begin
frmRelConsMembros.QRDBText77.enabled := false;
end;
if frmConfSist.CheckBox78.Checked = false  then
begin
frmRelConsMembros.QRDBText78.enabled := false;
end;
if frmConfSist.CheckBox79.Checked = false  then
begin
frmRelConsMembros.QRDBText79.enabled := false;
end;
if frmConfSist.CheckBox80.Checked = false  then
begin
frmRelConsMembros.QRDBText80.enabled := false;
end;
if frmConfSist.CheckBox81.Checked = false  then
begin
frmRelConsMembros.QRDBText81.enabled := false;
end;
if frmConfSist.CheckBox82.Checked = false  then
begin
frmRelConsMembros.QRDBText82.enabled := false;
end;
if frmConfSist.CheckBox83.Checked = false  then
begin
frmRelConsMembros.QRDBText83.enabled := false;
end;
if frmConfSist.CheckBox84.Checked = false  then
begin
frmRelConsMembros.QRDBText84.enabled := false;
end;



end;

procedure TfrmCons_Membros.FormKeyPress(Sender: TObject; var Key: Char);
begin
If key = #13 then
  Begin
  Key:= #0;
  Perform(Wm_NextDlgCtl,0,0);
  end;
end;

procedure TfrmCons_Membros.BitBtn1Click(Sender: TObject);
begin
frmMembros.Edit1.text := DBGrid1.SelectedField.Value ;
frmCons_Membros.Hide;
end;

procedure TfrmCons_Membros.DBLookupComboBox1Click(Sender: TObject);
begin
EditCelula.Text :=  DBLookupComboBox1.Text ;
end;

procedure TfrmCons_Membros.DBLookupComboBox2Click(Sender: TObject);
begin
EditEscola.Text :=  DBLookupComboBox2.Text ;
end;

procedure TfrmCons_Membros.DBLookupComboBox3Click(Sender: TObject);
begin
EditCargo.Text :=  DBLookupComboBox3.Text ;
end;

procedure TfrmCons_Membros.BitBtn2Click(Sender: TObject);
begin
EditCargo.Text := '';
end;

procedure TfrmCons_Membros.BitBtn3Click(Sender: TObject);
begin
EditEscola.Text := '';
end;

procedure TfrmCons_Membros.BitBtn4Click(Sender: TObject);
begin
EditCelula.Text := '';
end;

end.
