Пример #1
0
        public DashboardMainForm()
        {
            System.Threading.Thread.CurrentThread.CurrentUICulture = new System.Globalization.CultureInfo(Configuration.GetNewInstance().Settings.Language);
            InitializeComponent();

            if (System.Windows.Application.Current == null)
            {
                new System.Windows.Application();
            }

            host      = new ElementHost();
            host.Dock = DockStyle.Fill;

            this.toolStripContainer1.ContentPanel.Controls.Add(host);
            htmlOutputPath = string.Empty;
            dashboard      = new EpiDashboard.DashboardControl();
            dashboard.DashboardHelperRequested += new EpiDashboard.DashboardHelperRequestedHandler(dashboard_DashboardHelperRequested);
            dashboard.RelatedDataRequested     += new EpiDashboard.RelatedDataRequestedHandler(dashboard_RelatedDataRequested);
            dashboard.HTMLGenerated            += new EpiDashboard.HTMLGeneratedHandler(dashboard_HTMLGenerated);
            dashboard.RecordCountChanged       += new EpiDashboard.RecordCountChangedHandler(dashboard_RecordCountChanged);
            dashboard.CanvasChanged            += new EpiDashboard.CanvasChangedHandler(dashboard_CanvasChanged);
            this.FormClosed += new FormClosedEventHandler(DashboardMainForm_FormClosed);
            host.Child       = dashboard;
            this.Width++;
            this.Width--;

            this.toolStripContainer1.TopToolStripPanel.Visible = false;

            this.Text = SharedStrings.DASHBOARD_TITLE;
        }
Пример #2
0
        public DashboardMainForm()
        {
            System.Threading.Thread.CurrentThread.CurrentUICulture = new System.Globalization.CultureInfo(Configuration.GetNewInstance().Settings.Language);
            InitializeComponent();

            if (System.Windows.Application.Current == null) new System.Windows.Application();

            host = new ElementHost();
            host.Dock = DockStyle.Fill;

            this.toolStripContainer1.ContentPanel.Controls.Add(host);
            htmlOutputPath = string.Empty;
            dashboard = new EpiDashboard.DashboardControl();
            dashboard.DashboardHelperRequested += new EpiDashboard.DashboardHelperRequestedHandler(dashboard_DashboardHelperRequested);
            dashboard.RelatedDataRequested += new EpiDashboard.RelatedDataRequestedHandler(dashboard_RelatedDataRequested);
            dashboard.HTMLGenerated += new EpiDashboard.HTMLGeneratedHandler(dashboard_HTMLGenerated);
            dashboard.RecordCountChanged += new EpiDashboard.RecordCountChangedHandler(dashboard_RecordCountChanged);
            dashboard.CanvasChanged += new EpiDashboard.CanvasChangedHandler(dashboard_CanvasChanged);
            this.FormClosed += new FormClosedEventHandler(DashboardMainForm_FormClosed);
            host.Child = dashboard;
            this.Width++;
            this.Width--;

            this.toolStripContainer1.TopToolStripPanel.Visible = false;

            this.Text = SharedStrings.DASHBOARD_TITLE;
        }
Пример #3
0
 public void UnSubscribe()
 {
     this.Controls.Clear();
     this.host              = null;
     this.dashboard         = null;
     this.host              = null;
     this.enterMainForm     = null;
     this.currentView       = null;
     this.db                = null;
     this.loadedRuntimeView = null;
 }
Пример #4
0
 public void UnSubscribe()
 {
     this.Controls.Clear();
     this.host = null;            
     this.dashboard = null;
     this.host = null;
     this.enterMainForm = null;
     this.currentView = null;
     this.db = null;
     this.loadedRuntimeView = null;
 }
Пример #5
0
        public void Render(Epi.View view)
        {
            try
            {
                if (!view.IsRelatedView)
                {
                    EpiDashboard.DashboardHelper helper = new EpiDashboard.DashboardHelper(view, DBReadExecute.GetDataDriver(view.Project.FilePath));
                    dashboard = new EpiDashboard.DashboardControl(helper);

                    this.WindowState = FormWindowState.Maximized;

                    helper.SetDashboardControl(dashboard);
                    dashboard.RecordCountChanged += new EpiDashboard.RecordCountChangedHandler(dashboard_RecordCountChanged);
                    host.Child = dashboard;
                    dashboard.UpdateRecordCount();
                    dashboard.ReCacheDataSource();
                }
            }
            catch (Exception ex)
            {
                //temporarily catch all
            }
        }
Пример #6
0
        public void Render(Epi.View view)
        {
            try
            {
                if (!view.IsRelatedView)
                {
                    EpiDashboard.DashboardHelper helper = new EpiDashboard.DashboardHelper(view, DBReadExecute.GetDataDriver(view.Project.FilePath));
                    dashboard = new EpiDashboard.DashboardControl(helper);

                    this.WindowState = FormWindowState.Maximized;

                    helper.SetDashboardControl(dashboard);
                    dashboard.RecordCountChanged += new EpiDashboard.RecordCountChangedHandler(dashboard_RecordCountChanged);
                    host.Child = dashboard;
                    dashboard.UpdateRecordCount();
                    dashboard.ReCacheDataSource();
                }
            }
            catch (Exception ex)
            {
                //temporarily catch all
            }
        }