First commit 11/07/1998
This commit is contained in:
		
							
								
								
									
										14
									
								
								AcercaDe.cpp
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										14
									
								
								AcercaDe.cpp
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,14 @@
 | 
			
		||||
//---------------------------------------------------------------------
 | 
			
		||||
#include <vcl.h>
 | 
			
		||||
#pragma hdrstop
 | 
			
		||||
 | 
			
		||||
#include "AcercaDe.h"
 | 
			
		||||
//--------------------------------------------------------------------- 
 | 
			
		||||
#pragma resource "*.dfm"
 | 
			
		||||
TAboutBox *AboutBox;
 | 
			
		||||
//--------------------------------------------------------------------- 
 | 
			
		||||
__fastcall TAboutBox::TAboutBox(TComponent* AOwner)
 | 
			
		||||
	: TForm(AOwner)
 | 
			
		||||
{
 | 
			
		||||
}
 | 
			
		||||
//--------------------------------------------------------------------- 
 | 
			
		||||
							
								
								
									
										
											BIN
										
									
								
								AcercaDe.dfm
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								AcercaDe.dfm
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										35
									
								
								AcercaDe.h
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										35
									
								
								AcercaDe.h
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,35 @@
 | 
			
		||||
//----------------------------------------------------------------------------
 | 
			
		||||
#ifndef AcercaDeH
 | 
			
		||||
#define AcercaDeH
 | 
			
		||||
//----------------------------------------------------------------------------
 | 
			
		||||
#include <vcl\System.hpp>
 | 
			
		||||
#include <vcl\Windows.hpp>
 | 
			
		||||
#include <vcl\SysUtils.hpp>
 | 
			
		||||
#include <vcl\Classes.hpp>
 | 
			
		||||
#include <vcl\Graphics.hpp>
 | 
			
		||||
#include <vcl\Forms.hpp>
 | 
			
		||||
#include <vcl\Controls.hpp>
 | 
			
		||||
#include <vcl\StdCtrls.hpp>
 | 
			
		||||
#include <vcl\Buttons.hpp>
 | 
			
		||||
#include <vcl\ExtCtrls.hpp>
 | 
			
		||||
//----------------------------------------------------------------------------
 | 
			
		||||
class TAboutBox : public TForm
 | 
			
		||||
{
 | 
			
		||||
__published:
 | 
			
		||||
	TPanel *Panel1;
 | 
			
		||||
	TLabel *ProductName;
 | 
			
		||||
	TLabel *Version;
 | 
			
		||||
	TLabel *Copyright;
 | 
			
		||||
	TLabel *Comments;
 | 
			
		||||
	TButton *OKButton;
 | 
			
		||||
	TLabel *Label1;
 | 
			
		||||
	TLabel *Label2;
 | 
			
		||||
	TImage *ProgramIcon;
 | 
			
		||||
private:
 | 
			
		||||
public:
 | 
			
		||||
	virtual __fastcall TAboutBox(TComponent* AOwner);
 | 
			
		||||
};
 | 
			
		||||
//----------------------------------------------------------------------------
 | 
			
		||||
extern TAboutBox *AboutBox;
 | 
			
		||||
//----------------------------------------------------------------------------
 | 
			
		||||
#endif    
 | 
			
		||||
							
								
								
									
										
											BIN
										
									
								
								BCrack.XG0
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								BCrack.XG0
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										
											BIN
										
									
								
								BCrack.XG1
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								BCrack.XG1
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										
											BIN
										
									
								
								BCrack.XG2
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								BCrack.XG2
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										
											BIN
										
									
								
								BCrack.XG3
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								BCrack.XG3
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										
											BIN
										
									
								
								BCrack.XG4
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								BCrack.XG4
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										
											BIN
										
									
								
								BCrack.YG0
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								BCrack.YG0
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										
											BIN
										
									
								
								BCrack.YG1
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								BCrack.YG1
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										
											BIN
										
									
								
								BCrack.YG2
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								BCrack.YG2
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										
											BIN
										
									
								
								BCrack.YG3
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								BCrack.YG3
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										
											BIN
										
									
								
								BCrack.YG4
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								BCrack.YG4
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										212
									
								
								BCrack.cpp
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										212
									
								
								BCrack.cpp
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,212 @@
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
#include <stdlib.h>
 | 
			
		||||
#include <stdio.h>
 | 
			
		||||
 | 
			
		||||
#include <vcl\vcl.h>
 | 
			
		||||
#pragma hdrstop
 | 
			
		||||
 | 
			
		||||
#include <io.h>
 | 
			
		||||
 | 
			
		||||
#include "BCrack.h"
 | 
			
		||||
#include "AcercaDe.h"
 | 
			
		||||
#include "Busc1.h"
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
#pragma link "TB97"
 | 
			
		||||
#pragma link "Grids"
 | 
			
		||||
#pragma link "CoolForm"
 | 
			
		||||
#pragma link "ActivApp"
 | 
			
		||||
#pragma resource "*.dfm"
 | 
			
		||||
TForm1 *Form1;
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
__fastcall TForm1::TForm1(TComponent* Owner)
 | 
			
		||||
	: TForm(Owner)
 | 
			
		||||
{
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
void __fastcall TForm1::ToolbarButton972Click(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
  try {
 | 
			
		||||
    Table1 -> Prior();
 | 
			
		||||
  } catch(...){
 | 
			
		||||
  }
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
void __fastcall TForm1::ToolbarButton974Click(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
  try {
 | 
			
		||||
    Table1 -> Next();
 | 
			
		||||
  } catch(...){
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
void __fastcall TForm1::ToolbarButton971Click(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
  Close();	
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
void __fastcall TForm1::ToolbarButton977Click(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
  AboutBox -> ShowModal();
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
void __fastcall TForm1::Table1BeforeOpen(TDataSet *DataSet)
 | 
			
		||||
{
 | 
			
		||||
 if ( (access(Table1 -> TableName.c_str(), 0) != 0) )//! ( Table1 -> CheckOpen(0) ) )
 | 
			
		||||
 {
 | 
			
		||||
	 // Facilitamos el nombre de la nueva tabla y su tipo
 | 
			
		||||
	 Table1 -> TableType = ttParadox;
 | 
			
		||||
 | 
			
		||||
	 // Usamos la propiedad FielDefs para definir
 | 
			
		||||
	 // las columnas que contendr<64> la tabla
 | 
			
		||||
     Table1 -> FieldDefs -> Clear();
 | 
			
		||||
	 Table1 -> FieldDefs -> Add("indexed", ftAutoInc, 0, false );
 | 
			
		||||
	 Table1 -> FieldDefs -> Add("tCrack", ftString, 10, false );
 | 
			
		||||
	 Table1 -> FieldDefs -> Add("nCrack", ftString, 50, false );
 | 
			
		||||
	 Table1 -> FieldDefs -> Add("Nombre", ftString, 50, false );
 | 
			
		||||
	 Table1 -> FieldDefs -> Add("Fecha",  ftDate,    0, false );
 | 
			
		||||
	 Table1 -> FieldDefs -> Add("tProg",  ftString, 15, false );
 | 
			
		||||
 | 
			
		||||
     Table1 -> IndexDefs-> Clear();
 | 
			
		||||
 | 
			
		||||
     TIndexOptions Prim, MyIndexOptions;
 | 
			
		||||
     Prim << ixPrimary << ixUnique;
 | 
			
		||||
     MyIndexOptions << ixCaseInsensitive;
 | 
			
		||||
	 Table1->IndexDefs->Add("primary", "indexed", Prim);
 | 
			
		||||
 | 
			
		||||
	 Table1->IndexDefs->Add("itCrack", "tCrack", MyIndexOptions);
 | 
			
		||||
	 Table1->IndexDefs->Add("inCrack", "nCrack", MyIndexOptions);
 | 
			
		||||
	 Table1->IndexDefs->Add("iNombre", "Nombre", MyIndexOptions);
 | 
			
		||||
	 Table1->IndexDefs->Add("iFecha",  "Fecha",  MyIndexOptions);
 | 
			
		||||
	 Table1->IndexDefs->Add("itProg",  "tProg",  MyIndexOptions);
 | 
			
		||||
 | 
			
		||||
	 // Creamos la base...
 | 
			
		||||
	 Table1 -> CreateTable();
 | 
			
		||||
 }
 | 
			
		||||
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
void __fastcall TForm1::FormCreate(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
 | 
			
		||||
  Table1  -> TableName = "BCrack.db";
 | 
			
		||||
  TBuscar -> TableName = "BCrack.db";
 | 
			
		||||
 | 
			
		||||
  Table1 -> Active     = true;
 | 
			
		||||
  TBuscar-> Active     = true;
 | 
			
		||||
 | 
			
		||||
/*
 | 
			
		||||
  TDlgBuscProd *DlgBuscProd;
 | 
			
		||||
  DlgBuscProd = new  TDlgBuscProd(this);
 | 
			
		||||
*/
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
void __fastcall TForm1::ToolbarButton978Click(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
  DlgBuscProd -> ShowModal();
 | 
			
		||||
 | 
			
		||||
  if ( DlgBuscProd -> ModalResult == mrOk )
 | 
			
		||||
  {
 | 
			
		||||
     BusqSig -> Enabled = true;
 | 
			
		||||
     BusqAnt -> Enabled = true;
 | 
			
		||||
     Table1 -> GotoCurrent(TBuscar);
 | 
			
		||||
  }
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
void __fastcall TForm1::BusqSigClick(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
  if ( TBuscar -> FindNext() == true )
 | 
			
		||||
  {
 | 
			
		||||
   Table1 -> GotoCurrent(TBuscar);
 | 
			
		||||
   BusqAnt -> Enabled = true;
 | 
			
		||||
  } else {
 | 
			
		||||
   BusqSig -> Enabled = false;
 | 
			
		||||
   MessageBox( 0, "Coincidencia no hayada", "<EFBFBD> Buscar Siguiente !", MB_OK );
 | 
			
		||||
  }
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
void __fastcall TForm1::BusqAntClick(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
  if ( TBuscar -> FindPrior() == true )
 | 
			
		||||
  {
 | 
			
		||||
   Table1 -> GotoCurrent(TBuscar);
 | 
			
		||||
   BusqSig -> Enabled = true;
 | 
			
		||||
  } else {
 | 
			
		||||
   BusqAnt -> Enabled = false;
 | 
			
		||||
   MessageBox( 0, "Coincidencia no hayada", "<EFBFBD> Buscar Anterior !", MB_OK );
 | 
			
		||||
  }
 | 
			
		||||
}
 | 
			
		||||
void __fastcall TForm1::Table1NewRecord(TDataSet *DataSet)
 | 
			
		||||
{
 | 
			
		||||
  Table1 -> FieldByName( "Fecha" ) -> AsDateTime = TDateTime::CurrentDate();	
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
void __fastcall TForm1::DataSource1DataChange(TObject *Sender, TField *Field)
 | 
			
		||||
{
 | 
			
		||||
  char BarraEstado[80];
 | 
			
		||||
 | 
			
		||||
  // Indicador de FichaActual / Num.Fichas
 | 
			
		||||
  if ( Table1 -> RecNo > 0 && Table1 -> RecordCount > 0 )
 | 
			
		||||
  {
 | 
			
		||||
   sprintf( BarraEstado, "%d / %d", Table1 -> RecNo, Table1 -> RecordCount );
 | 
			
		||||
  } else {
 | 
			
		||||
   sprintf( BarraEstado, "<EFBFBD>Nuevo? / %d", Table1 -> RecordCount );
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  StatusBar1->Panels->Items[1]->Text = BarraEstado;
 | 
			
		||||
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
void __fastcall TForm1::ToolbarButton976Click(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
  bool Success;
 | 
			
		||||
  // Run crack...
 | 
			
		||||
  ActivApp1 -> ExePath = "start ..\\Cracks\\" + Table1 -> FieldByName("nCrack") -> AsString;
 | 
			
		||||
  ActivApp1 -> ExecuteApp( &Success );
 | 
			
		||||
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
void __fastcall TForm1::FormDestroy(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
/*
 | 
			
		||||
  delete DlgBuscProd;
 | 
			
		||||
*/  
 | 
			
		||||
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
 | 
			
		||||
void __fastcall TForm1::Edit1Change(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
 | 
			
		||||
      AnsiString BuscarCota;
 | 
			
		||||
      BuscarCota = Edit1->Text + "Z";
 | 
			
		||||
 | 
			
		||||
      TBuscar->FilterOptions = Form1 -> TBuscar->FilterOptions << foCaseInsensitive;
 | 
			
		||||
 | 
			
		||||
      TBuscar->Filtered = true;
 | 
			
		||||
      TBuscar->Filter = "([Nombre] >= '" + Edit1->Text + "') AND [Nombre] < '" + BuscarCota + "'";
 | 
			
		||||
 | 
			
		||||
try {
 | 
			
		||||
  Table1 -> GotoCurrent(TBuscar);
 | 
			
		||||
} catch(...)
 | 
			
		||||
{
 | 
			
		||||
 //do nothing
 | 
			
		||||
}
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
 | 
			
		||||
void __fastcall TForm1::DBGrid1Enter(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
  DBGrid1 -> Options = DBGrid1 -> Options >> dgRowSelect >> dgAlwaysShowSelection  << dgEditing;
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
 | 
			
		||||
void __fastcall TForm1::DBGrid1Exit(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
  DBGrid1 -> Options = DBGrid1 -> Options << dgAlwaysShowSelection << dgRowSelect; 
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										
											BIN
										
									
								
								BCrack.dfm
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								BCrack.dfm
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										70
									
								
								BCrack.h
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										70
									
								
								BCrack.h
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,70 @@
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
#ifndef BCrackH
 | 
			
		||||
#define BCrackH
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
#include <vcl\Classes.hpp>
 | 
			
		||||
#include <vcl\Controls.hpp>
 | 
			
		||||
#include <vcl\StdCtrls.hpp>
 | 
			
		||||
#include <vcl\Forms.hpp>
 | 
			
		||||
#include "TB97.hpp"
 | 
			
		||||
#include <vcl\ComCtrls.hpp>
 | 
			
		||||
#include <vcl\DBGrids.hpp>
 | 
			
		||||
#include "Grids.hpp"
 | 
			
		||||
#include <vcl\DBTables.hpp>
 | 
			
		||||
#include <vcl\DB.hpp>
 | 
			
		||||
#include "CoolForm.hpp"
 | 
			
		||||
#include <vcl\ExtCtrls.hpp>
 | 
			
		||||
#include <Db.hpp>
 | 
			
		||||
#include <DBCGrids.hpp>
 | 
			
		||||
#include <DBCtrls.hpp>
 | 
			
		||||
#include <Mask.hpp>
 | 
			
		||||
#include "ActivApp.hpp"
 | 
			
		||||
#include <Graphics.hpp>
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
class TForm1 : public TForm
 | 
			
		||||
{
 | 
			
		||||
__published:	// IDE-managed Components
 | 
			
		||||
	TTable *Table1;
 | 
			
		||||
	TDataSource *DataSource1;
 | 
			
		||||
	TTable *TBuscar;
 | 
			
		||||
	TCoolForm *CoolForm1;
 | 
			
		||||
	TPanel *Panel1;
 | 
			
		||||
	TStatusBar *StatusBar1;
 | 
			
		||||
	TShape *Shape1;
 | 
			
		||||
	TShape *Shape2;
 | 
			
		||||
	TShape *Shape3;
 | 
			
		||||
	TShape *Shape4;
 | 
			
		||||
	TShape *Shape5;
 | 
			
		||||
    TDBEdit *DBEdit1;
 | 
			
		||||
    TDBGrid *DBGrid1;
 | 
			
		||||
    TDBEdit *DBEdit2;
 | 
			
		||||
    TDBComboBox *DBComboBox1;
 | 
			
		||||
    TLabel *Label1;
 | 
			
		||||
    TLabel *Label2;
 | 
			
		||||
    TEdit *Edit1;
 | 
			
		||||
	void __fastcall ToolbarButton972Click(TObject *Sender);
 | 
			
		||||
	void __fastcall ToolbarButton974Click(TObject *Sender);
 | 
			
		||||
	void __fastcall BusqAntClick(TObject *Sender);
 | 
			
		||||
	void __fastcall BusqSigClick(TObject *Sender);
 | 
			
		||||
	void __fastcall ToolbarButton971Click(TObject *Sender);
 | 
			
		||||
	void __fastcall ToolbarButton977Click(TObject *Sender);
 | 
			
		||||
	void __fastcall Table1BeforeOpen(TDataSet *DataSet);
 | 
			
		||||
	void __fastcall FormCreate(TObject *Sender);
 | 
			
		||||
	void __fastcall ToolbarButton978Click(TObject *Sender);
 | 
			
		||||
	void __fastcall Table1NewRecord(TDataSet *DataSet);
 | 
			
		||||
	void __fastcall DataSource1DataChange(TObject *Sender, TField *Field);
 | 
			
		||||
	
 | 
			
		||||
    void __fastcall ToolbarButton976Click(TObject *Sender);
 | 
			
		||||
    
 | 
			
		||||
    void __fastcall FormDestroy(TObject *Sender);
 | 
			
		||||
    void __fastcall Edit1Change(TObject *Sender);
 | 
			
		||||
    void __fastcall DBGrid1Enter(TObject *Sender);
 | 
			
		||||
    void __fastcall DBGrid1Exit(TObject *Sender);
 | 
			
		||||
private:	// User declarations
 | 
			
		||||
public:		// User declarations
 | 
			
		||||
	__fastcall TForm1(TComponent* Owner);
 | 
			
		||||
};
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
extern TForm1 *Form1;
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
#endif
 | 
			
		||||
							
								
								
									
										26
									
								
								BCrack1.cpp
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										26
									
								
								BCrack1.cpp
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,26 @@
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
#include <vcl\vcl.h>
 | 
			
		||||
#pragma hdrstop
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
USEFORM("BCrack.cpp", Form1);
 | 
			
		||||
USERES("BCrack1.res");
 | 
			
		||||
USEFORM("AcercaDe.cpp", AboutBox);
 | 
			
		||||
USEFORM("Busc1.cpp", DlgBuscProd);
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
WINAPI WinMain(HINSTANCE, HINSTANCE, LPSTR, int)
 | 
			
		||||
{
 | 
			
		||||
	try
 | 
			
		||||
	{
 | 
			
		||||
		Application->Initialize();
 | 
			
		||||
		Application->CreateForm(__classid(TForm1), &Form1);
 | 
			
		||||
        Application->CreateForm(__classid(TAboutBox), &AboutBox);
 | 
			
		||||
        Application->CreateForm(__classid(TDlgBuscProd), &DlgBuscProd);
 | 
			
		||||
        Application->Run();
 | 
			
		||||
	}
 | 
			
		||||
	catch (Exception &exception)
 | 
			
		||||
	{
 | 
			
		||||
		Application->ShowException(&exception);
 | 
			
		||||
	}
 | 
			
		||||
	return 0;
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
							
								
								
									
										
											BIN
										
									
								
								BCrack1.exe
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								BCrack1.exe
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										107
									
								
								BCrack1.mak
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										107
									
								
								BCrack1.mak
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,107 @@
 | 
			
		||||
# ---------------------------------------------------------------------------
 | 
			
		||||
VERSION = BCB.03
 | 
			
		||||
# ---------------------------------------------------------------------------
 | 
			
		||||
!ifndef BCB
 | 
			
		||||
BCB = $(MAKEDIR)\..
 | 
			
		||||
!endif
 | 
			
		||||
# ---------------------------------------------------------------------------
 | 
			
		||||
PROJECT = BCrack1.exe
 | 
			
		||||
OBJFILES = BCrack1.obj BCrack.obj AcercaDe.obj Busc1.obj
 | 
			
		||||
RESFILES = BCrack1.res
 | 
			
		||||
RESDEPEN = $(RESFILES) BCrack.dfm AcercaDe.dfm Busc1.dfm
 | 
			
		||||
LIBFILES = 
 | 
			
		||||
LIBRARIES = vcldbx35.lib vcldb35.lib vclx35.lib vcl35.lib
 | 
			
		||||
SPARELIBS = vcl35.lib vclx35.lib vcldb35.lib vcldbx35.lib
 | 
			
		||||
PACKAGES = VCLX35.bpi VCL35.bpi VCLDB35.bpi VCLDBX35.bpi bcbsmp35.bpi dclocx35.bpi \
 | 
			
		||||
  QRPT35.bpi TEEUI35.bpi TEEDB35.bpi TEE35.bpi ibsmp35.bpi NMFAST35.bpi \
 | 
			
		||||
  INETDB35.bpi INET35.bpi JDsoft.bpi
 | 
			
		||||
PATHASM = .;
 | 
			
		||||
PATHCPP = .;
 | 
			
		||||
PATHPAS = .;
 | 
			
		||||
PATHRC = .;
 | 
			
		||||
DEBUGLIBPATH = $(BCB)\lib\debug
 | 
			
		||||
RELEASELIBPATH = $(BCB)\lib\release
 | 
			
		||||
DEFFILE =
 | 
			
		||||
# ---------------------------------------------------------------------------
 | 
			
		||||
CFLAG1 = -Od -Hc -w -Ve -r- -k -y -v -vi- -c -b- -w-par -w-inl -Vx
 | 
			
		||||
CFLAG2 = -I"L:\Progra~1\Jd Soft";$(BCB)\include;$(BCB)\include\vcl -H=$(BCB)\lib\vcld.csm
 | 
			
		||||
CFLAG3 =
 | 
			
		||||
PFLAGS = -AWinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE \
 | 
			
		||||
  -U"L:\Progra~1\Jd Soft";$(BCB)\lib\obj;$(BCB)\lib;$(DEBUGLIBPATH) \
 | 
			
		||||
  -I"L:\Progra~1\Jd Soft";$(BCB)\include;$(BCB)\include\vcl -$Y -$W -$O- -v \
 | 
			
		||||
  -JPHNV -M
 | 
			
		||||
RFLAGS = -i"L:\Progra~1\Jd Soft";$(BCB)\include;$(BCB)\include\vcl
 | 
			
		||||
AFLAGS = /i"L:\Progra~1\Jd Soft" /i$(BCB)\include /i$(BCB)\include\vcl /mx /w2 /zd
 | 
			
		||||
LFLAGS = -L"L:\Progra~1\Jd Soft";$(BCB)\lib\obj;$(BCB)\lib;$(DEBUGLIBPATH) -aa -Tpe -x -v
 | 
			
		||||
IFLAGS =
 | 
			
		||||
LINKER = ilink32
 | 
			
		||||
# ---------------------------------------------------------------------------
 | 
			
		||||
ALLOBJ = c0w32.obj sysinit.obj $(OBJFILES)
 | 
			
		||||
ALLRES = $(RESFILES)
 | 
			
		||||
ALLLIB = $(LIBFILES) $(LIBRARIES) import32.lib cp32mt.lib
 | 
			
		||||
# ---------------------------------------------------------------------------
 | 
			
		||||
.autodepend
 | 
			
		||||
 | 
			
		||||
!ifdef IDEOPTIONS
 | 
			
		||||
 | 
			
		||||
[Version Info]
 | 
			
		||||
IncludeVerInfo=0
 | 
			
		||||
AutoIncBuild=0
 | 
			
		||||
MajorVer=1
 | 
			
		||||
MinorVer=0
 | 
			
		||||
Release=0
 | 
			
		||||
Build=0
 | 
			
		||||
Debug=0
 | 
			
		||||
PreRelease=0
 | 
			
		||||
Special=0
 | 
			
		||||
Private=0
 | 
			
		||||
DLL=0
 | 
			
		||||
Locale=3082
 | 
			
		||||
CodePage=1252
 | 
			
		||||
 | 
			
		||||
[HistoryLists\hlIncludePath]
 | 
			
		||||
Count=1
 | 
			
		||||
Item0=L:\Progra~1\Jd Soft;$(BCB)\include;$(BCB)\include\vcl
 | 
			
		||||
 | 
			
		||||
[HistoryLists\hlLibraryPath]
 | 
			
		||||
Count=1
 | 
			
		||||
Item0=L:\Progra~1\Jd Soft;$(BCB)\lib\obj;$(BCB)\lib
 | 
			
		||||
 | 
			
		||||
[HistoryLists\hlUnitAliases]
 | 
			
		||||
Count=1
 | 
			
		||||
Item0=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE
 | 
			
		||||
 | 
			
		||||
[Debugging]
 | 
			
		||||
DebugSourceDirs=
 | 
			
		||||
 | 
			
		||||
[Parameters]
 | 
			
		||||
RunParams=
 | 
			
		||||
HostApplication=
 | 
			
		||||
 | 
			
		||||
!endif
 | 
			
		||||
 | 
			
		||||
$(PROJECT): $(OBJFILES) $(RESDEPEN) $(DEFFILE)
 | 
			
		||||
    $(BCB)\BIN\$(LINKER) @&&!
 | 
			
		||||
    $(LFLAGS) +
 | 
			
		||||
    $(ALLOBJ), +
 | 
			
		||||
    $(PROJECT),, +
 | 
			
		||||
    $(ALLLIB), +
 | 
			
		||||
    $(DEFFILE), +
 | 
			
		||||
    $(ALLRES) 
 | 
			
		||||
!
 | 
			
		||||
 | 
			
		||||
.pas.hpp:
 | 
			
		||||
    $(BCB)\BIN\dcc32 $(PFLAGS) { $** }
 | 
			
		||||
 | 
			
		||||
.pas.obj:
 | 
			
		||||
    $(BCB)\BIN\dcc32 $(PFLAGS) { $** }
 | 
			
		||||
 | 
			
		||||
.cpp.obj:
 | 
			
		||||
    $(BCB)\BIN\bcc32 $(CFLAG1) $(CFLAG2) -o$* $* 
 | 
			
		||||
 | 
			
		||||
.c.obj:
 | 
			
		||||
    $(BCB)\BIN\bcc32 $(CFLAG1) $(CFLAG2) -o$* $**
 | 
			
		||||
 | 
			
		||||
.rc.res:
 | 
			
		||||
    $(BCB)\BIN\brcc32 $(RFLAGS) $<
 | 
			
		||||
#-----------------------------------------------------------------------------
 | 
			
		||||
							
								
								
									
										
											BIN
										
									
								
								BCrack1.res
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								BCrack1.res
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										91
									
								
								Busc1.cpp
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										91
									
								
								Busc1.cpp
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,91 @@
 | 
			
		||||
#pragma link "Grids"
 | 
			
		||||
#include "BCrack.h"
 | 
			
		||||
//---------------------------------------------------------------------
 | 
			
		||||
#include <vcl.h>
 | 
			
		||||
#pragma hdrstop
 | 
			
		||||
 | 
			
		||||
#include "Busc1.h"
 | 
			
		||||
#include "BCrack.h"
 | 
			
		||||
 | 
			
		||||
//---------------------------------------------------------------------
 | 
			
		||||
#pragma link "Grids"
 | 
			
		||||
#pragma resource "*.dfm"
 | 
			
		||||
 | 
			
		||||
TDlgBuscProd *DlgBuscProd;
 | 
			
		||||
//---------------------------------------------------------------------
 | 
			
		||||
__fastcall TDlgBuscProd::TDlgBuscProd(TComponent* AOwner)
 | 
			
		||||
	: TForm(AOwner)
 | 
			
		||||
{
 | 
			
		||||
  Form1 -> TBuscar->FieldByName("Nombre")->Index = 0;
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------
 | 
			
		||||
void __fastcall TDlgBuscProd::ComboBox1Change(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
  // Make the field we're locating in the leftmost field.
 | 
			
		||||
  Form1 -> TBuscar->FieldByName(ComboBox1->Text)->Index = 0;
 | 
			
		||||
/*
 | 
			
		||||
  // In order to use FindNearest, we have to be indexed based on the field
 | 
			
		||||
  // we're doing the find in.  If we're using Locate, it doesn't matter what
 | 
			
		||||
  // the current index is, so we will set it to company, which is the default
 | 
			
		||||
  // in the Customer form.
 | 
			
		||||
 | 
			
		||||
  if (ComboBox1->Text == "CustNo")
 | 
			
		||||
*/
 | 
			
		||||
    Form1 -> TBuscar->IndexName = "";
 | 
			
		||||
 | 
			
		||||
/*
 | 
			
		||||
  else
 | 
			
		||||
    DM2->CustLookup->IndexName = "ByCompany";
 | 
			
		||||
*/
 | 
			
		||||
 | 
			
		||||
  Edit1->SetFocus();
 | 
			
		||||
  Edit1->Text = "";
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
void __fastcall TDlgBuscProd::Edit1Change(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
  AnsiString BuscarEsto;
 | 
			
		||||
 | 
			
		||||
  BuscarEsto = Edit1->Text;
 | 
			
		||||
 | 
			
		||||
  { // Some non-indexed field.
 | 
			
		||||
    if ( //ComboBox1->Text != "Nombre del Producto"  &&
 | 
			
		||||
         BuscarEsto == "" )
 | 
			
		||||
        BuscarEsto = "0";
 | 
			
		||||
 | 
			
		||||
    Set<TLocateOption,0,1> flags;
 | 
			
		||||
    flags << loCaseInsensitive << loPartialKey;
 | 
			
		||||
    // Possibly apply the filter so we see only records matching this value.
 | 
			
		||||
    bool found;
 | 
			
		||||
    found = Form1 -> TBuscar->Locate(ComboBox1->Text,
 | 
			
		||||
                                    BuscarEsto,
 | 
			
		||||
                                    flags);
 | 
			
		||||
 | 
			
		||||
    if ( found )
 | 
			
		||||
    {
 | 
			
		||||
      AnsiString BuscarCota;
 | 
			
		||||
      BuscarCota = BuscarEsto + "Z";
 | 
			
		||||
 | 
			
		||||
      Form1 -> TBuscar->FilterOptions = Form1 -> TBuscar->FilterOptions << foCaseInsensitive;
 | 
			
		||||
 | 
			
		||||
      Form1 -> TBuscar->Filtered = true;
 | 
			
		||||
      Form1 -> TBuscar->Filter = "([" + ComboBox1->Text + "] >= '" + BuscarEsto + "') AND [" + ComboBox1->Text + "] < '" + BuscarCota + "'";
 | 
			
		||||
    }
 | 
			
		||||
    else
 | 
			
		||||
      Form1 -> TBuscar->Filtered = false;
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  Form1 -> TBuscar->Refresh();
 | 
			
		||||
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
void __fastcall TDlgBuscProd::DBGrid1DblClick(TObject *Sender)
 | 
			
		||||
{
 | 
			
		||||
  ModalResult = mrOk;
 | 
			
		||||
}
 | 
			
		||||
//---------------------------------------------------------------------------
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										45
									
								
								Busc1.h
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										45
									
								
								Busc1.h
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,45 @@
 | 
			
		||||
//----------------------------------------------------------------------------
 | 
			
		||||
#ifndef Busc1H
 | 
			
		||||
#define Busc1H
 | 
			
		||||
//----------------------------------------------------------------------------
 | 
			
		||||
#include <vcl\ExtCtrls.hpp>
 | 
			
		||||
#include <vcl\Buttons.hpp>
 | 
			
		||||
#include <vcl\StdCtrls.hpp>
 | 
			
		||||
#include <vcl\Controls.hpp>
 | 
			
		||||
#include <vcl\Forms.hpp>
 | 
			
		||||
#include <vcl\Graphics.hpp>
 | 
			
		||||
#include <vcl\Classes.hpp>
 | 
			
		||||
#include <vcl\SysUtils.hpp>
 | 
			
		||||
#include <vcl\Windows.hpp>
 | 
			
		||||
#include <vcl\System.hpp>
 | 
			
		||||
#include <vcl\DBGrids.hpp>
 | 
			
		||||
#include <vcl\DBTables.hpp>
 | 
			
		||||
#include <vcl\DB.hpp>
 | 
			
		||||
#include "Grids.hpp"
 | 
			
		||||
#include <Db.hpp>
 | 
			
		||||
//----------------------------------------------------------------------------
 | 
			
		||||
class TDlgBuscProd : public TForm
 | 
			
		||||
{
 | 
			
		||||
__published:
 | 
			
		||||
	TButton *OKBtn;
 | 
			
		||||
	TButton *CancelBtn;
 | 
			
		||||
	TBevel *Bevel1;
 | 
			
		||||
	TDBGrid *DBGrid1;
 | 
			
		||||
	TComboBox *ComboBox1;
 | 
			
		||||
	TEdit *Edit1;
 | 
			
		||||
	TLabel *Label1;
 | 
			
		||||
	TLabel *Label2;
 | 
			
		||||
	TDataSource *DataSource1;
 | 
			
		||||
	void __fastcall ComboBox1Change(TObject *Sender);
 | 
			
		||||
	void __fastcall Edit1Change(TObject *Sender);
 | 
			
		||||
	
 | 
			
		||||
	void __fastcall DBGrid1DblClick(TObject *Sender);
 | 
			
		||||
	
 | 
			
		||||
private:
 | 
			
		||||
public:
 | 
			
		||||
	virtual __fastcall TDlgBuscProd(TComponent* AOwner);
 | 
			
		||||
};
 | 
			
		||||
//----------------------------------------------------------------------------
 | 
			
		||||
extern TDlgBuscProd *DlgBuscProd;
 | 
			
		||||
//----------------------------------------------------------------------------
 | 
			
		||||
#endif    
 | 
			
		||||
							
								
								
									
										9
									
								
								README.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								README.md
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,9 @@
 | 
			
		||||
#06-jul-2002 
 | 
			
		||||
 
 | 
			
		||||
 
 | 
			
		||||
*11/07/1998* 
 | 
			
		||||
 
 | 
			
		||||
ToDo: wwtcf? 
 | 
			
		||||
 
 | 
			
		||||
 
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										
											BIN
										
									
								
								bcrack.BMP
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								bcrack.BMP
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							| 
		 After Width: | Height: | Size: 126 KiB  | 
							
								
								
									
										
											BIN
										
									
								
								bcrack.psd
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								bcrack.psd
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										3
									
								
								cleanup.bat
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										3
									
								
								cleanup.bat
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,3 @@
 | 
			
		||||
del *.~*
 | 
			
		||||
del *.tds
 | 
			
		||||
del *.obj
 | 
			
		||||
		Reference in New Issue
	
	Block a user