Exemplo n.º 1
0
        private void HCSAnalyzer_Load(object sender, EventArgs e)
        {
            GlobalInfo = new cGlobalInfo(CompleteScreening, this);

            // GlobalInfo.WindowName = this.Text;
            this.Text = GlobalInfo.WindowName + String.Format("Version {0}", Assembly.GetExecutingAssembly().GetName().Version.ToString()) + " (Scalar Mode)";

            GlobalInfo.OptionsWindow.Visible = false;
            GlobalInfo.ComboForSelectedDesc = this.comboBoxDescriptorToDisplay;
            GlobalInfo.CheckedListBoxForDescActive = this.checkedListBoxActiveDescriptors;

            //new Kitware.VTK.RenderWindowControl novelRender = new RenderWindowControl

            GlobalInfo.renderWindowControlForVTK = null;//renderWindowControlForVTK;

            MyConsole = new FormConsole();
            MyConsole.Visible = false;

            PlateListWindow = new PlatesListForm();
            GlobalInfo.PlateListWindow = PlateListWindow;

            GlobalInfo.panelForPlate = this.panelForPlate;

            comboBoxClass.SelectedIndex = 1;
        }
Exemplo n.º 2
0
        private void HCSAnalyzer_Load(object sender, EventArgs e)
        {
            //System.Threading.Thread thdWorker = new ... (MethodToCall);
            // System.Threading.Thread thdWorker = new System.Threading.Thread(MyLoad);
            // thdWorker.Start();

            GlobalInfo = new cGlobalInfo(this);

            panelForTools.Controls.Add(cGlobalInfo.GUIPlateLUT.AssociatedPanel);


            this.comboBoxClass.Items.Add("Inactive");
            foreach (var item in cGlobalInfo.ListWellClasses)
            {
                this.comboBoxClass.Items.Add(item.Name);
                //this.comboBoxClass.Items[this.comboBoxClass.Items.Count-1].
            }


            // GlobalInfo.WindowName = this.Text;
            this.Text = cGlobalInfo.WindowName + " (Scalar Mode)";

            cGlobalInfo.OptionsWindow.Visible = false;
            cGlobalInfo.ComboForSelectedDesc = this.comboBoxDescriptorToDisplay;
            cGlobalInfo.CheckedListBoxForDescActive = this.checkedListBoxActiveDescriptors;

            //new Kitware.VTK.RenderWindowControl novelRender = new RenderWindowControl

            cGlobalInfo.renderWindowControlForVTK = null;//renderWindowControlForVTK;

            PlateListWindow = new PlatesListForm();
            cGlobalInfo.PlateListWindow = PlateListWindow;

            cGlobalInfo.panelForPlate = this.panelForPlate;

            comboBoxClass.SelectedIndex = 1;


            // CheckBox cb = new CheckBox();
            //cb.Text = "test";
            //cb.CheckStateChanged += (s, ex) =>
            //this.Text = cb.CheckState.ToString();
            //ToolStripControlHost host = new ToolStripControlHost(cb);
            //toolStrip1.Items.Insert(0,host);



            // this.toolStripMain.DataBindings.Add("Checked", this.checkBox1, "Checked");


            checkBoxDisplayClasses.Text = "Display Class";
            checkBoxDisplayClasses.Appearance = Appearance.Button;
            checkBoxDisplayClasses.FlatStyle = FlatStyle.Popup;
            checkBoxDisplayClasses.CheckedChanged += new EventHandler(checkBoxDisplayClasses_CheckedChanged);

            ToolStripControlHost host = new ToolStripControlHost(checkBoxDisplayClasses);
            toolStripMain.Items.Insert(0, host);

            checkBoxApplyTo_AllPlates.Text = "Apply to all plates";
            checkBoxApplyTo_AllPlates.Appearance = Appearance.Button;
            checkBoxApplyTo_AllPlates.FlatStyle = FlatStyle.Popup;
            checkBoxApplyTo_AllPlates.Checked = true;
            checkBoxApplyTo_AllPlates.CheckedChanged += new EventHandler(checkBoxApplyTo_AllPlates_CheckedChanged);

            ToolStripControlHost hostcheckBoxApplyTo_AllPlates = new ToolStripControlHost(checkBoxApplyTo_AllPlates);
            toolStripMain.Items.Insert(3, hostcheckBoxApplyTo_AllPlates);

            ToolStripControlHost Host_TrackBarForZoom = new ToolStripControlHost(XTrackBarForZoom.panel);
            statusStripMain.Items.Insert(1, Host_TrackBarForZoom);

            // check command line arguments and process them
            if (System.Environment.GetCommandLineArgs().Length > 1)
            {
                List<string> LArg = new List<string>();
                int FileMode = 0;
                foreach (string arg in System.Environment.GetCommandLineArgs())
                {
                    if (arg.ToLower() == "-todb")
                    {
                        FileMode = 1;
                    }
                    else
                    {
                        LArg.Add(System.Environment.GetCommandLineArgs()[1]);
                    }
                }

                if (FileMode == 0)
                {
                    FormForImportExcel CSVFeedBackWindow = LoadCSVAssay(LArg.ToArray(), false);
                    if (CSVFeedBackWindow == null) return;
                    if (CSVFeedBackWindow.ShowDialog() != System.Windows.Forms.DialogResult.OK) return;
                    ProcessOK(CSVFeedBackWindow);

                    UpdateUIAfterLoading();
                    return;
                }
                else if (FileMode == 1)
                {
                    CSVtoDB(LArg[0],",","");

                    return;
                }
            }
            // delete the current Log file
            File.Delete("HCSA.log");
            //  this.BringToFront();
            //MyLoad();
        }
Exemplo n.º 3
0
        private void HCSAnalyzer_Load(object sender, EventArgs e)
        {
            GlobalInfo = new cGlobalInfo(CompleteScreening);
            GlobalInfo.OptionsWindow.Visible = false;
            GlobalInfo.ComboForSelectedDesc = this.comboBoxDescriptorToDisplay;
            GlobalInfo.CheckedListBoxForDescActive = this.checkedListBoxActiveDescriptors;

            //new Kitware.VTK.RenderWindowControl novelRender = new RenderWindowControl

            GlobalInfo.renderWindowControlForVTK = null;//renderWindowControlForVTK;

            MyConsole = new FormConsole();
            MyConsole.Visible = false;

            PlateListWindow = new PlatesListForm();
            GlobalInfo.PlateListWindow = PlateListWindow;

            GlobalInfo.panelForPlate = this.panelForPlate;

            comboBoxClass.SelectedIndex = 1;
        }