当前位置: 首页>>代码示例>>C#>>正文


C# Form2.Activate方法代码示例

本文整理汇总了C#中Form2.Activate方法的典型用法代码示例。如果您正苦于以下问题:C# Form2.Activate方法的具体用法?C# Form2.Activate怎么用?C# Form2.Activate使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Form2的用法示例。


在下文中一共展示了Form2.Activate方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: ecranBleu

 public void ecranBleu()
 {
     Form2 bsod = new Form2();
     Cursor.Hide();
     bsod.Show();
     bsod.Activate();
 }
开发者ID:Betcheg,项目名称:RatonLaveur,代码行数:7,代码来源:Source.cs

示例2: barButtonItemTest_ItemClick

        private void barButtonItemTest_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            try
            {
                FormGenConfigClass frm = new FormGenConfigClass();
                frm.MdiParent = this;

                frm.Show();

                Form1 frm2 = new Form1();
                frm2.MdiParent = this;
                frm2.Show();

                Form2 frm22 = new Form2();
                if (frm22.IsMdiContainer)
                {
                    frm22.IsMdiContainer = false;
                    frm22.MdiParent = this;
                }
                else
                {
                    frm22.MdiParent = this;
                }

                frm22.StartPosition = FormStartPosition.CenterScreen;
                frm22.Show();
                frm22.Activate();

                UserControl1 cl = new UserControl1();

                Form1 frm211 = new Form1();

                frm211.Controls.Add(cl);
                frm211.IsMdiContainer = false;
                frm211.MdiParent = this;
                frm211.Show();

            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }
开发者ID:sunpander,项目名称:VSDT,代码行数:43,代码来源:FormMain.cs

示例3: TryToConnect

        public void TryToConnect()
        {
            // Start Running
            StartProgressBar();
            tsslP.Text = "Initalize...";

            //initalize

            // Start the listener thread
            Thread oThread = new Thread(new ThreadStart(listener));
            oThread.Start();

            //Creates Connection to the local DB

            if (m_houseID != 0 && m_user != null && !m_connected)
            {
                this.isActive = false;
                // try to connect
                Form2 f = new Form2(this);
                f.Activate();
                f.Show();

            }

            if (m_connected)
            {
                allDeviceInHouseDetailesProcTableAdapter.Fill(smarthousedbDataSet.allDeviceInHouseDetailesProc, m_houseID);
                tsslTD.Text = "Login Time: " + DateTime.Now.ToString("HH:mm:ss tt");
                tsslP.Text = "Ready";
            }
            else
            {
                tsslTD.Text = "Failed to Login connection is lost: " + DateTime.Now.ToString("HH:mm:ss tt");
                tsslP.Text = "Error";
            }

            StopProgressBar();
        }
开发者ID:ogolov,项目名称:SmartHouse,代码行数:38,代码来源:Form1.cs

示例4: setSailEnterPortToolStripMenuItem_Click

 private void setSailEnterPortToolStripMenuItem_Click(object sender, EventArgs e)
 {
     Form2 f = new Form2();
     f.Show();
     f.Activate();
     f.move(connection);
 }
开发者ID:B-Rich,项目名称:Task37774,代码行数:7,代码来源:Form1.cs

示例5: button3_Click

 private void button3_Click(object sender, EventArgs e)
 {
     if (folderBrowserDialog1.ShowDialog() == DialogResult.OK)
     {
         string[] files = Directory.GetFiles(folderBrowserDialog1.SelectedPath);
         string foundPath = "";
         foreach (string sFile in files)
         {
             if (sFile.Substring(sFile.Length - 6) == "_0.!mv")
             {
                 foundPath = sFile;
                 break;
             }
         }
         if (foundPath == "")
         {
             MessageBox.Show("在选择的目录下未能找到所需要的文件!", "错误");
         }
         else
         {
             Hide();
             Form2 frm2 = new Form2(this, foundPath);
             frm2.Show();
             frm2.Activate();
         }
     }
 }
开发者ID:slurin,项目名称:mobile-qvod-file-converter,代码行数:27,代码来源:Form1.cs

示例6: button1_Click

 private void button1_Click(object sender, EventArgs e)
 {
     int idx=(int)listBox1.SelectedIndex;
     //MessageBox.Show((string)foundFiles[i]);
     if (idx < 0)
     {
         MessageBox.Show("请从列表中选择一项再继续!", "无效操作");
         return;
     }
     Hide();
     Form2 frm2 = new Form2(this, (string)foundFiles[idx]);
     //frm2.
     frm2.Show();
     frm2.Activate();
 }
开发者ID:slurin,项目名称:mobile-qvod-file-converter,代码行数:15,代码来源:Form1.cs

示例7: SubtitlesButton_Click

 private void SubtitlesButton_Click(object sender, EventArgs e)
 {
     form_subtitle = new Form2();
     form_subtitle.Activate();
     form_subtitle.Show();
 }
开发者ID:RajShahCrazy,项目名称:Humble-Video-Converter---Processor,代码行数:6,代码来源:Form1.cs

示例8: toolStripMenuItem6_Click

        private void toolStripMenuItem6_Click(object sender, EventArgs e)
        {
            this.isActive = false;
            // Open connection
            Form2 login = new Form2(this);
            login.Activate();
            login.Show();

              //  while (!this.isActive)
              //  { }
        }
开发者ID:ogolov,项目名称:SmartHouse,代码行数:11,代码来源:Form1.cs


注:本文中的Form2.Activate方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。