Example #1
0
 /// <summary>
 /// 得到GroupByRow
 /// </summary>
 /// <returns></returns>
 public static MyGroupByRow GetGroupByRow(this IGrid grid)
 {
     foreach (Row row in grid.FixedHeaderRows)
     {
         MyGroupByRow r = row as MyGroupByRow;
         if (r != null)
         {
             return(r);
         }
     }
     return(null);
 }
 private void tsmGroup_Click(object sender, EventArgs e)
 {
     tsmGroup.Checked = !tsmGroup.Checked;
     if (tsmGroup.Checked)
     {
         m_grid.FixedHeaderRows.Insert(0, new BoundGridGroupByRow());
     }
     else
     {
         MyGroupByRow row = m_grid.GetGroupByRow();
         if (row != null)
         {
             m_grid.FixedHeaderRows.Remove(row);
         }
     }
 }
Example #3
0
 /// <summary>
 /// Constructor
 /// </summary>
 /// <param name="template"></param>
 public MyGroupByRow(MyGroupByRow template)
     : base(template)
 {
     this.NoGroupText = title;
 }
 /// <summary>
 /// Constructor
 /// </summary>
 /// <param name="template"></param>
 public MyGroupByRow(MyGroupByRow template)
     : base(template)
 {
     this.NoGroupText = title;
 }