zoukankan      html  css  js  c++  java
  • 关于tabControl 选项卡事件

    1、DoubleClick
     #region /***双击选项卡*/
      /// <summary>
      /// 双击选项卡,分别加载E,P信息界面数据
      /// </summary>
      /// <param name="sender"></param>
      /// <param name="e"></param>
      private void tabExamPaper_DoubleClick(object sender, System.EventArgs e)
      {
       TabControl   tc=(TabControl)sender;
     
       switch(tc.SelectedIndex)
       {
        case 0:
         //加载E相关数据
         LoadEData();
         ClearECombox();
         break;
        case 1:
         //加载P相关数据
         LoadPData();
         ClearPCombox();
         break;
       }
      }

    2、SelectedIndexChanged
    #region /***点选项卡***/
      private void tabExamPaper_SelectedIndexChanged(object sender, System.EventArgs e)
      {
       //   if (this.tabEPaper.SelectedTab==this.tbpE)
       //   {
       //    MessageBox.Show("Exam");
       //   }
         
       switch(this.tabExamPaper.SelectedIndex)
       {
        case 0:
         //     MessageBox.Show("tabPage1 is Selected");
         //     FillComboxData();
         //    //填充DataGrid
         //    addDataGridData();
          break;
        case 1:
         //加载P相关数据
         //     LoadPData();
         break;
       }
      }

  • 相关阅读:
    2017洛谷7月月赛总结
    poj3169 Layout
    poj3613Cow Relays
    洛谷P1418 选点问题
    poj3311Hie with the Pie
    poj1734Sightseeing trip
    poj3728The merchant
    洛谷P2420 让我们异或吧
    struts2.1笔记02:servlet简介
    struts2.1笔记01:MVC框架思想浅层理解
  • 原文地址:https://www.cnblogs.com/flashicp/p/773974.html
Copyright © 2011-2022 走看看