unit P_vereinssystem;
{$mode objfpc}{$H+}
interface
uses
Classes, SysUtils, FileUtil, PrintersDlgs, Forms, Controls, Graphics, Dialogs,
ComCtrls, StdCtrls, Buttons, ExtDlgs, Calendar, FileCtrl, EditBtn, CheckLst,
ColorBox, Menus, ExtCtrls, ValEdit, MaskEdit, ActnList;
type
{ TForm1 }
TForm1 = class(TForm)
btnClose: TBitBtn;
btnSave: TButton;
btnMonE: TButton;
btnQuartE: TButton;
btnJE: TButton;
btnMonK: TButton;
btnQuartK: TButton;
btnHJK: TButton;
btnJK: TButton;
btnLoad: TButton;
edtHJE: TButton;
edtoffVon: TEdit;
edtoffBetr: TEdit;
edtBeitragPro: TEdit;
edtEmail: TEdit;
edtTel: TEdit;
edtOrt: TEdit;
edtPLZ: TEdit;
edtAdr: TEdit;
edtMBTG: TEdit;
edtMitglS: TEdit;
edtAlterst: TEdit;
edtNachn: TEdit;
edtVorn: TEdit;
Label1: TLabel;
Label2: TLabel;
edtoffB: TLabel;
Label3: TLabel;
Label4: TLabel;
lblTurn: TLabel;
lblEmail: TLabel;
lblTel: TLabel;
lblOrt: TLabel;
lblPLZ: TLabel;
lblAdr: TLabel;
lblMBTG: TLabel;
lblMitglS: TLabel;
lblAltersst: TLabel;
lblNNname: TLabel;
lblVName: TLabel;
mem12: TMemo;
MemTurn: TMemo;
StatusBar1: TStatusBar;
procedure Action1Execute(Sender: TObject);
procedure btnCloseClick(Sender: TObject);
procedure btnJEClick(Sender: TObject);
procedure btnJKClick(Sender: TObject);
procedure btnLoadClick(Sender: TObject);
procedure btnMonEClick(Sender: TObject);
procedure btnMonKClick(Sender: TObject);
procedure btnQuartEClick(Sender: TObject);
procedure btnQuartKClick(Sender: TObject);
procedure btnSaveClick(Sender: TObject);
procedure btnHJKClick(Sender: TObject);
procedure CheckGroup1Click(Sender: TObject);
procedure chk1Change(Sender: TObject);
procedure edtHJEClick(Sender: TObject);
procedure edtoffBetrChange(Sender: TObject);
procedure edtVornChange(Sender: TObject);
procedure FormCreate(Sender: TObject);
procedure Image1Click(Sender: TObject);
procedure ListBox1Click(Sender: TObject);
procedure mem12Change(Sender: TObject);
procedure MemTurnChange(Sender: TObject);
procedure MenuItem1Click(Sender: TObject);
procedure PageControl1Change(Sender: TObject);
procedure ValueListEditor1Click(Sender: TObject);
private
{ private declarations }
public
{ public declarations }
end;
var
Form1: TForm1;
implementation
{$R *.lfm}
{ TForm1 }
procedure TForm1.MemTurnChange(Sender: TObject);
begin
end;
procedure TForm1.MenuItem1Click(Sender: TObject);
begin
end;
procedure TForm1.PageControl1Change(Sender: TObject);
begin
end;
procedure TForm1.ValueListEditor1Click(Sender: TObject);
begin
end;
procedure TForm1.edtVornChange(Sender: TObject);
begin
end;
procedure TForm1.FormCreate(Sender: TObject);
begin
end;
procedure TForm1.Image1Click(Sender: TObject);
begin
end;
procedure TForm1.ListBox1Click(Sender: TObject);
begin
end;
procedure TForm1.mem12Change(Sender: TObject);
begin
end;
procedure TForm1.Action1Execute(Sender: TObject);
begin
end;
procedure TForm1.btnCloseClick(Sender: TObject);
begin
end;
procedure TForm1.btnJEClick(Sender: TObject);
var a,b,c : Single;
begin
a := StrToFloat (edtoffBetr.Text) ;
b := a+72;
edtoffBetr.Text := FloatToStr(b);
end;
procedure TForm1.btnJKClick(Sender: TObject);
var a,b : Single;
begin
a := StrToFloat (edtoffBetr.Text) ;
b := a+54;
edtoffBetr.Text := FloatToStr(b);
end;
procedure TForm1.btnLoadClick(Sender: TObject);
var
List: TStrings;
begin
List:=TStringList.Create;
try
List.LoadfromFile('C:/Mitgliederverwaltung/Mitglieder/'+ edtVorn.Text + edtNachn.Text +'.MG');
if List.Count>0 then
edtVorn.Text:=List[0] ;
edtNachn.Text:=List[1] ;
edtAlterst.Text:=List[2];
edtMitglS.Text:=List[3];
edtMBTG.Text:=List[4];
edtBeitragPro.Text:=List[13];
edtoffBetr.Text:=List[14];
edtoffVon.Text:=List[15];
edtAdr.Text:=List[5];
edtPLZ.Text:=List[6];
edtOrt.Text:=List[7];
edtTel.Text:=List[8];
edtEmail.Text:=List[9];
MemTurn.Text:=List[10];
finally
List.Free;
end;
end;
procedure TForm1.btnMonEClick(Sender: TObject);
var a,b,c : Single;
begin
a := StrToFloat (edtoffBetr.Text) ;
b := a+6;
edtoffBetr.Text := floatToStr(b);
end;
procedure TForm1.btnMonKClick(Sender: TObject);
var a,b,c : Single;
begin
a := StrToFloat (edtoffBetr.Text) ;
b := a+4.50;
edtoffBetr.Text := FloatToStr(b);
end;
procedure TForm1.btnQuartEClick(Sender: TObject);
var a,b,c : Single;
begin
a := StrToFloat (edtoffBetr.Text) ;
b := a+18;
edtoffBetr.Text := FloatToStr(b);
end;
procedure TForm1.btnQuartKClick(Sender: TObject);
var a,b,c : Single;
begin
a := StrToFloat (edtoffBetr.Text) ;
b := a+13.50;
edtoffBetr.Text := FloatToStr(b);
end;
procedure TForm1.btnSaveClick(Sender: TObject);
var
List:TStrings;
begin
List := TStringList.Create;
try
List.Add('Vorname: '+edtVorn.Text);
List.Add('Nachname: '+edtNachn.Text);
List.Add('Altersstufe: '+edtAlterst.Text);
List.Add('Mitglied seit: '+edtMitglS.Text);
List.Add('Mitgliedbeitrag: '+edtMBTG.Text + '€' + '/' + edtBeitragPro.Text);
List.Add('Adresse: '+edtAdr.Text);
List.Add('Postleihzahl: '+edtPLZ.Text);
List.Add('Ort: '+edtOrt.Text);
List.Add('Telefon: '+edtTel.Text);
List.Add('EMail: '+edtEmail.Text);
List.Add('Turniere: '+MemTurn.Text);
List.Add('offene Beträge: '+edtoffBetr.Text + '/' + edtoffVon.Text +'€');
if not DirectoryExists('C:/Mitgliederverwaltung/Mitglieder/') then
ForceDirectories('C:/Mitgliederverwaltung/Mitglieder/');
List.SaveToFile('C:/Mitgliederverwaltung/Mitglieder/'+edtVorn.Text + edtNachn.Text +'.MG');
finally
List.Free;
end;
end;
procedure TForm1.btnHJKClick(Sender: TObject);
var a,b,c : Single;
begin
a := StrToFloat (edtoffBetr.Text) ;
b := a+27;
edtoffBetr.Text := FloatToStr(b);
end;
procedure TForm1.edtoffBetrChange(Sender: TObject);
begin
end;
procedure TForm1.CheckGroup1Click(Sender: TObject);
begin
end;
procedure TForm1.chk1Change(Sender: TObject);
begin
end;
procedure TForm1.edtHJEClick(Sender: TObject);
var a,b,c : Single;
begin
a := StrToFloat (edtoffBetr.Text) ;
b := a+36;
edtoffBetr.Text := FloatToStr(b);
end;
end.