unit Unit1;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, ExtCtrls, StdCtrls,Unit2, jpeg;
type
TForm1 = class(TForm)
Panel1: TPanel;
Image1: TImage;
StaticText1: TStaticText;
StaticText2: TStaticText;
StaticText3: TStaticText;
StaticText4: TStaticText;
StaticText5: TStaticText;
GroupBox1: TGroupBox;
Button1: TButton;
Button2: TButton;
Edit1: TEdit;
StaticText6: TStaticText;
Image2: TImage;
procedure Button1Click(Sender: TObject);
procedure Button2Click(Sender: TObject);
procedure FormCreate(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
Form2: TForm2;
implementation
{$R *.dfm}
procedure TForm1.Button1Click(Sender: TObject);
var PAR : string;
begin
PAR:=Edit1.Text;
If PAR='orion 17' Then
begin
Form2:=TForm2.Create(Application);
Form2.ShowModal;
Form2.Free;
Edit1.Clear;
end
else
begin
if MessageDlg('Парольневірний! Значення " '+Edit1.Text+' " не є паролем! Звернітьсядорозробника',
mtError,[mbOK],0)=mrOK then
Edit1.Clear;
end;
end;
procedure TForm1.Button2Click(Sender: TObject);
begin
close;
end;
procedure TForm1.FormCreate(Sender: TObject);
begin
Image1.Picture.LoadFromFile('star.jpg');
Image2.Picture.LoadFromFile('star2.jpg');
end;
end.
unit Unit2;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,Math,
Dialogs, StdCtrls, ExtCtrls,Unit3,KonstPLN,Eagth,Mars,Jupiter,Saturn,Mercury,
Venus,Uran,Neptun,Pluton, Common,Unit4;
type
TForm2 = class(TForm)
Panel1: TPanel;
GroupBox1: TGroupBox;
GroupBox2: TGroupBox;
GroupBox3: TGroupBox;
GroupBox4: TGroupBox;
Button1: TButton;
Button2: TButton;
Button3: TButton;
Button4: TButton;
Image1: TImage;
Image2: TImage;
RadioButton1: TRadioButton;
---------------------------
RadioButton9: TRadioButton;
StaticText1: TStaticText;
----------------------------
StaticText5: TStaticText;
ComboBox1: TComboBox;
ComboBox2: TComboBox;
ComboBox3: TComboBox;
Edit1: TEdit;
Edit2: TEdit;
Label1: TLabel;
---------------------------
Label46: TLabel;
procedure RadioButton1Click(Sender: TObject);
----------------------------------------------
procedure RadioButton9Click(Sender: TObject);
procedure FormCreate(Sender: TObject);
procedure Button1Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form2: TForm2;
Form3: TForm3;
PLN,D0,M0,R0,i,DR,n : integer;
FI,LB,k,S0,P0,RM, ED,EG,ER,ER0,ESD,EH,ER1,EGD,
AD,AG,AR,x,AR0,ASD,AH,AR1,AGD, AAD1,ARS,AZE,AZP,
ABD,AV,AYD,AYDS,AAD0,AAD,AA,AAM,AAS,AID1,AID2,AID,AB,ABM,AF, AT1,ATK,ATKL,
ATKLM,AP,AT2,AT3,ATG,ATS,ATSL,ATSLM,ATZ,ATZL,ATZLM,AZ,AAH,ABG,ATKLH,
ATSLH,ATZLH :real;
implementation
{$R *.dfm}
procedure TForm2.Button4Click(Sender: TObject);
begin
MessageDlg('Інформація! Деякігеографічнікоординати:'+#13+'Чортків FI=49.03, LB=25.83'+#13+'Тернопіль FI=49.6, LB=25.6'+#13+'Львів FI=49.8, LB=24'+#13+'Київ FI=50.5, LB=30.5'+#13+'Лондон(Грінвіч) FI=51.6, LB=0'
,mtInformation,[mbOK],0);
end;
procedure TForm2.Button3Click(Sender: TObject);
begin
close;
end;
procedure TForm2.RadioButton1Click(Sender: TObject);
begin
PLN:=1;ZPL:=1; ZPL1:=1;
Image1.Picture.LoadFromFile('mercury.jpg');
end;
------------------------------------------------------
procedure TForm2.RadioButton9Click(Sender: TObject);
begin
PLN:=9; ZPL:=9; ZPL1:=9;
Image1.Picture.LoadFromFile('pluton.jpg');
end;
procedure TForm2.FormCreate(Sender: TObject);
begin
Image1.Picture.LoadFromFile('star1.jpg');
Image2.Picture.LoadFromFile('sun.bmp');
ComboBox1.ItemIndex:=8;
ComboBox2.ItemIndex:=0;
ComboBox3.ItemIndex:=0;
Label4.Visible:=false;
----------------------
Label46.Visible:=false;
Button2.Enabled:=false;
end;
procedure TForm2.Button1Click(Sender: TObject);
begin
Button2.Enabled:=false;
Label4.Visible:=false;
------------------------
Label46.Visible:=false;
if PLN=0 then //захиствідпомилки
begin
if MessageDlg(' Ви забули вибрати планету!'+#13+'По замовчуванню буде вибрана Земля.'
,mtError,[mbOK],0)=mrOK then
begin
RadioButton3.Checked:=true;
PLN:=3;
Image1.Picture.LoadFromFile('eath.jpg');
end;
end;
D0:=StrToInt(ComboBox1.Text);
ZD:=StrToInt(ComboBox1.Text);
ZD1:=StrToInt(ComboBox1.Text);
if (D0<=0) or( D0>31) then //захиствіддурня
begin
if MessageDlg('Помилка введення номера дня місяця!'
,mtError,[mbOK],0)=mrOK then
begin
ComboBox1.ItemIndex:=8;
D0:=StrToInt(ComboBox1.Text);
ZD:=StrToInt(ComboBox1.Text);
ZD1:=StrToInt(ComboBox1.Text);
end;
end;
if ComboBox2.ItemIndex=0 then
begin
M0:=1;ZM:=1; ZM1:=1;
end;
-----------------------------------
if ComboBox2.ItemIndex=11 then
begin