//---------------------------------------------------------------------------

#ifndef TAS00801FH
#define TAS00801FH
//---------------------------------------------------------------------------
#include <Classes.hpp>
#include <Controls.hpp>
#include <StdCtrls.hpp>
#include <Forms.hpp>
#include <DB.hpp>
#include <DBClient.hpp>
#include <Provider.hpp>
#include <ExtCtrls.hpp>
#include <Graphics.hpp>
#include <Buttons.hpp>
#include <ADODB.hpp>
#include <Menus.hpp>
//---------------------------------------------------------------------------
#include "WindowMsgF.h"
#include "DataTypesF.h"
#include "PlugInChartF.h"
#include "CDSColSysF.h"
#include "CDSStat0080F.h"
#include "CDSVdsCtlrF.h"
#include "cxButtons.hpp"
#include "cxCalc.hpp"
#include "cxCheckBox.hpp"
#include "cxClasses.hpp"
#include "cxContainer.hpp"
#include "cxControls.hpp"
#include "cxCustomData.hpp"
#include "cxData.hpp"
#include "cxDataStorage.hpp"
#include "cxEdit.hpp"
#include "cxFilter.hpp"
#include "cxGraphics.hpp"
#include "cxGrid.hpp"
#include "cxGridCustomTableView.hpp"
#include "cxGridCustomView.hpp"
#include "cxGridLevel.hpp"
#include "cxGridTableView.hpp"
#include "cxLabel.hpp"
#include "cxLookAndFeelPainters.hpp"
#include "cxLookAndFeels.hpp"
#include "cxSplitter.hpp"
#include "cxStyles.hpp"
#include "cxTextEdit.hpp"
#include "dxmdaset.hpp"
#include "dxSkinBlue.hpp"
#include "dxSkinsCore.hpp"
#include "dxSkinscxPCPainter.hpp"
//---------------------------------------------------------------------------

class TTAS00801 : public TForm
{
__published:	// IDE-managed Components
    TADOQuery *ADOQry;
    TTimer *TmrShow;
    TPanel *PnlTop;
    TPanel *PnlList;
    TcxSplitter *cxSplitter1;
    TLabel *LblSearch;
    TImage *ImgDesc01;
    TLabel *LblRecords;
    TcxButton *BtnExlSave;
    TPanel *PnlChart;
    TcxGrid *CxList;
    TcxGridTableView *TvList;
    TcxGridColumn *ColRoad;
    TcxGridColumn *Column02;
    TcxGridColumn *ColFName;
    TcxGridColumn *ColTName;
    TcxGridColumn *Column01;
    TcxGridColumn *Column03;
    TcxGridColumn *Column04;
    TcxGridColumn *Column05;
    TcxGridColumn *Column06;
    TcxGridColumn *Column07;
    TcxGridColumn *Column08;
    TcxGridColumn *Column09;
    TcxGridColumn *Column10;
    TcxGridColumn *Column11;
    TcxGridColumn *Column12;
    TcxGridColumn *Column13;
    TcxGridColumn *Column14;
    TcxGridColumn *Column15;
    TcxGridColumn *Column16;
    TcxGridColumn *Column17;
    TcxGridColumn *Column18;
    TcxGridLevel *GlList;
    TcxCheckBox *ChkExpand;
    TdxMemData *dxMemData1;
    void __fastcall FormShow(TObject *Sender);
    void __fastcall TmrShowTimer(TObject *Sender);
    void __fastcall ChkExpandClick(TObject *Sender);
    void __fastcall BtnExlSaveClick(TObject *Sender);
    void __fastcall FormClose(TObject *Sender, TCloseAction &Action);
    void __fastcall FormDestroy(TObject *Sender);
    void __fastcall FormCreate(TObject *Sender);
    void __fastcall CbOptionPropertiesChange(TObject *Sender);
private:	// User declarations
    TcxDataController  *m_pGDC;
    TcxGridColumn *FColumn[MAX_COLSYS];
    TcxGridChartSeries *FChart[MAX_COLSYS];
    TVdsCtlrManager   *MyManager;

public:
    TPlugInChart    *m_pFrmChart;
    HWND     FParent;

    String   FStDay, FEdDay, FStHour, FEdHour, FWeek, FDir, FAtrdNm;
    int      FTable, FQryType;

    TStat0080Manager      *FStatManager;
    TStat0080ChartManager *FChartManager;

public:		// User declarations
    __fastcall TTAS00801(TComponent* Owner, HWND hHandle,
                         String AStDay, String AEdDay, String AStHour, String AEdHour, String AWeek, String ADir, String AAtrdNm, int ATable, int AQryType, TVdsCtlrManager* AManager);
	__fastcall ~TTAS00801(void);

    void __fastcall OnMessage(TMessage &Msg);

    void __fastcall CommClose();

    void __fastcall FormInit();
    void __fastcall SelHistory1();

    void __fastcall DspHistory();
    void __fastcall DrawChart(String ATitle);
    String __fastcall GetDayWeekCode(String ADay);

};
//---------------------------------------------------------------------------
extern PACKAGE TTAS00801 *TAS00801;
//---------------------------------------------------------------------------
#endif

