Beispiel #1
0
        void PingLoading(int stat)
        {
            if (this.InvokeRequired)
            {
                PingLoadingCallback d = new PingLoadingCallback(PingLoading);
                this.Invoke(d, new object[] { stat });
            }
            else
            {
                progressBar1.Value = stat;

                if (this.label1.Visible)
                {
                    this.label1.Visible = false;

                    this.label1.Text = "Loading.";
                    this.label1.Text = "Loading..";
                    this.label1.Text = "Loading...";
                    this.label1.Text = "Loading....";
                    this.label1.Text = "Loading.....";
                    this.label1.Text = "Loading......";
                }
                else
                {
                    this.label1.Visible = true;

                    this.label1.Text = "Loading.";
                    this.label1.Text = "Loading..";
                    this.label1.Text = "Loading...";
                    this.label1.Text = "Loading....";
                    this.label1.Text = "Loading.....";
                    this.label1.Text = "Loading......";
                }

                if (stat == 16)
                {
                    if (flag)
                    {
                        flag = false;

                        time2.Enabled = false;

                        if (formName == "onlinestat")
                        {
                            TDService.mainForm.online = new OnlinleStat();

                            TDService.mainForm.online.ShowDialog();
                        }

                        if (formName == "database")
                        {
                            (new DataBaseInitial()).ShowDialog();
                        }

                        if (formName == "alarmlog")
                        {
                            (new AlarmLog()).ShowDialog();
                        }

                        if (formName == "banglog")
                        {
                            (new BangLog()).ShowDialog();
                        }

                        if (formName == "EmptyBangSel")
                        {
                            (new EmptyBangSel()).ShowDialog();
                        }

                        if (formName == "FM_WeightBangSearch")
                        {
                            (new FM_WeightBangSearch()).ShowDialog();
                        }
                        if (formName == "SetIP")
                        {
                            (new SetIP()).ShowDialog();
                        }
                        this.Close();
                    }
                }
            }
        }
Beispiel #2
0
        void PingLoading(int stat)
        {
            if (this.InvokeRequired)
            {
                PingLoadingCallback d = new PingLoadingCallback(PingLoading);
                this.Invoke(d, new object[] { stat });
            }
            else
            {
                progressBar1.Value = stat ;

                if (this.label1.Visible)
                {
                    this.label1.Visible = false;

                    this.label1.Text = "Loading.";
                    this.label1.Text = "Loading..";
                    this.label1.Text = "Loading...";
                    this.label1.Text = "Loading....";
                    this.label1.Text = "Loading.....";
                    this.label1.Text = "Loading......";
                }
                else
                {
                    this.label1.Visible = true;

                    this.label1.Text = "Loading.";
                    this.label1.Text = "Loading..";
                    this.label1.Text = "Loading...";
                    this.label1.Text = "Loading....";
                    this.label1.Text = "Loading.....";
                    this.label1.Text = "Loading......";
                }

                if (stat ==16)
                {
                    if (flag)
                    {
                        flag = false;

                        time2.Enabled = false;

                        if (formName == "onlinestat")
                        {
                            TDService.mainForm.online = new OnlinleStat();

                            TDService.mainForm.online.ShowDialog();
                        }

                        if (formName == "database")
                        {
                            (new DataBaseInitial()).ShowDialog();
                        }

                        if (formName == "alarmlog")
                        {
                            (new AlarmLog()).ShowDialog();
                        }

                        if (formName == "banglog")
                        {
                            (new BangLog()).ShowDialog();
                        }

                        if (formName == "EmptyBangSel")
                        {
                            (new EmptyBangSel()).ShowDialog();
                        }

                        if (formName == "FM_WeightBangSearch")
                        {
                            (new FM_WeightBangSearch()).ShowDialog();
                        }
                        if (formName == "SetIP")
                        {
                            (new SetIP()).ShowDialog();
                        }
                        this.Close();
                    }
                }

            }
        }