コード例 #1
0
 protected override void OnColumnWidthChanged(DataGridViewColumnEventArgs e)
 {
     base.OnColumnWidthChanged(e);
     if (!string.IsNullOrEmpty(_zxmlname))
     {
         string path = Application.StartupPath + "\\" + _zxmlname;
         XmlHelperEx.Update(path, "DataGridViewColumns/Column[@cname='" + e.Column.Name + "']", "Width", e.Column.Width.ToString());
     }
 }
コード例 #2
0
ファイル: JMDataGridView.cs プロジェクト: jxj050928/Kim
 void ContextMenu_ColumnVisbleChange(bool cstate, string _cname)
 {
     this.Columns[_cname].Visible = cstate;
     if (!string.IsNullOrEmpty(_zxmlname))
     {
         string path = Application.StartupPath + "\\" + _zxmlname;
         XmlHelperEx.Update(path, "DataGridViewColumns/Column[@cname='" + _cname + "']/Visble", "", cstate.ToString());
     }
 }
コード例 #3
0
ファイル: JMDataGridView.cs プロジェクト: jxj050928/Kim
 protected override void OnMouseUp(MouseEventArgs e)
 {
     base.OnMouseUp(e);
     if (e.Y <= this.ColumnHeadersHeight)
     {
         if (!string.IsNullOrEmpty(_zxmlname))
         {
             string path = Application.StartupPath + "\\" + _zxmlname;
             foreach (DataGridViewColumn column in this.Columns)
             {
                 XmlHelperEx.Update(path, "DataGridViewColumns/Column[@cname='" + column.Name + "']/DisplayIndex", "", column.DisplayIndex.ToString());
             }
         }
     }
 }
コード例 #4
0
 protected override void OnMouseUp(MouseEventArgs e)
 {
     // used to keep extra mouse moves from selecting more rows when collapsing
     base.OnMouseUp(e);
     this._inExpandCollapseMouseCapture = false;
     if (e.Y <= this.ColumnHeadersHeight)
     {
         if (!string.IsNullOrEmpty(_zxmlname))
         {
             string path = Application.StartupPath + "\\" + _zxmlname;
             foreach (DataGridViewColumn column in this.Columns)
             {
                 XmlHelperEx.Update(path, "DataGridViewColumns/Column[@cname='" + column.Name + "']/DisplayIndex", "", column.DisplayIndex.ToString());
             }
         }
     }
 }