deea

Download deea

If you can't read please download the document

Upload: andreea-claudia

Post on 24-Dec-2015

214 views

Category:

Documents


0 download

DESCRIPTION

sxsax

TRANSCRIPT

//---------------------------------------------------------------------------#include #pragma hdrstop#include "Unit1.h"#include "Unit2.h"#include "Unit3.h"//---------------------------------------------------------------------------#pragma package(smart_init)#pragma resource "*.dfm"TForm1 *Form1;//---------------------------------------------------------------------------__fastcall TForm1::TForm1(TComponent* Owner) : TForm(Owner){}//---------------------------------------------------------------------------void __fastcall TForm1::FormActivate(TObject *Sender){ListBox1->ItemIndex = 0;ListBox1->OnClick(this);Top = 0;Left = 0;Width = 1024;Height = 768;}//---------------------------------------------------------------------------void __fastcall TForm1::ListBox1Click(TObject *Sender){AnsiString a = ListBox1->Items->Strings[ListBox1->ItemIndex];Memo1->Lines->LoadFromFile("judete\\"+a+"\\"+a+".txt.txt");Image1->Picture->LoadFromFile("judete\\"+a+"\\"+a+".jpg.jpg");}//---------------------------------------------------------------------------void __fastcall TForm1::Image1Click(TObject *Sender){AnsiString a = ListBox1->Items->Strings[ListBox1->ItemIndex];Form2->Image1->Picture->LoadFromFile("judete\\"+a+"\\"+a+".jpg.jpg");Form2->Image1->Top = 0;Form2->Image1->Left = 0;Form2->Position = poScreenCenter;Form2->Caption = a;Form2->ShowModal();}//---------------------------------------------------------------------------void __fastcall TForm1::Button2Click(TObject *Sender){Close();}//---------------------------------------------------------------------------void __fastcall TForm1::Button1Click(TObject *Sender){Form3->ShowModal();}//---------------------------------------------------------------------------