//--------------------------------------------------------------------------- #ifndef FrmDbPrgressFH #define FrmDbPrgressFH //--------------------------------------------------------------------------- #include #include #include #include #include #include #include #include "cxContainer.hpp" #include "cxControls.hpp" #include "cxEdit.hpp" #include "cxGraphics.hpp" #include "cxLookAndFeelPainters.hpp" #include "cxLookAndFeels.hpp" #include "cxProgressBar.hpp" #include "dxSkinBlack.hpp" #include "dxSkinBlue.hpp" #include "dxSkinsCore.hpp" //--------------------------------------------------------------------------- class TDBThread : public TThread { private: TADOQuery *m_ADOQry; protected: TForm *FParentForm; void __fastcall Execute(); public: __fastcall TDBThread(); void __fastcall SetQry(TADOQuery *adoQry, TForm *AForm); }; class TFrmDbProgress : public TForm { __published: // IDE-managed Components TButton *btnCancel; TcxProgressBar *PbProgress; TTimer *TmrProgress; TLabel *Label1; TEdit *Edit1; void __fastcall FormShow(TObject *Sender); void __fastcall btnCancelClick(TObject *Sender); void __fastcall TmrProgressTimer(TObject *Sender); void __fastcall FormClose(TObject *Sender, TCloseAction &Action); private: // User declarations TForm *FParentForm; public: // User declarations __fastcall TFrmDbProgress(TComponent* Owner); TDBThread *m_pThrDb; void __fastcall Init(String sCaption, int nMax, bool bCancel=false, bool bTimer=false); void __fastcall Step(String sText, int nPos); void __fastcall SetQry(TADOQuery *adoQry); void __fastcall TermThread(); }; //--------------------------------------------------------------------------- //extern PACKAGE TFrmDbProgress *FrmDbProgress; //--------------------------------------------------------------------------- #endif