//---------------------------------------------------------------------------
#include
#pragma hdrstop
#include "Unit1.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma link "frxpngimage"
#pragma link "sSkinManager"
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Image1Click(TObject *Sender)
{
Form1->Close();
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Image2Click(TObject *Sender)
{
Panel2->Visible=false;
Panel1->Visible=true;
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Button1Click(TObject *Sender)
{
Panel2->Visible=true;
Panel1->Visible=false;
Edit3->Text="s";
Edit3->Text="";
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Button2Click(TObject *Sender)
{
ADOQuery1->Insert();
Panel2->Visible=false;
Panel3->Visible=true;
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Button6Click(TObject *Sender)
{
Panel2->Visible=true;
Panel3->Visible=false;
ADOQuery1->Cancel();
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Button3Click(TObject *Sender)
{
ADOQuery1->Edit();
Panel2->Visible=false;
Panel3->Visible=true;
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Button4Click(TObject *Sender)
{
if(ADOQuery1->FieldByName("name")->AsString!="")
{
ADOQuery1->Delete();
}
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Button5Click(TObject *Sender)
{
ADOQuery1->Post();
Panel2->Visible=true;
Panel3->Visible=false;
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Edit3Change(TObject *Sender)
{
ADOQuery1->Close();
ADOQuery1->SQL->Clear();
ADOQuery1->SQL->Add("SELECT *FROM maxsulotlar WHERE `name` like '"+Edit3->Text+"%'");
ADOQuery1->Open();
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Y1Click(TObject *Sender)
{
ShowMessage("Ushbu dastur sport muassasalarini maxsulotlanini nazorat qilish dasturi.");
}
//---------------------------------------------------------------------------
void __fastcall TForm1::D1Click(TObject *Sender)
{
ShowWarning("Ushbu dastur Qahhorov Abdurahmon Dadaxon o'g'li tomonidan tayorlandi!");
}
//---------------------------------------------------------------------------
Do'stlaringiz bilan baham: |