08 2008 档案

摘要:匹配1;2;3 的正则表达式 public static bool IsValidPage(string strIn,int b) { bool aa = Regex.IsMatch(strIn, @"([a-zA-Z0-9];){"+(b-1).ToString()+"}([a-zA-Z0-9])$"); return aa; ... 阅读全文

posted @ 2008-08-28 17:00 J-Pei 阅读(266) 评论(0) 推荐(0)

摘要:用CellEndEdit事件触发函数去响应cell值的改变. combbox绑定的问题,我把datagridview的那一列定义成DataGridViewComboBoxColumn,然后再把指定cell强制转换为datagridviewcomboboxcell就可以绑定数据了. // 你可以在DataGridView的EditingControlShowing事件中加入如下代码,来给你的C... 阅读全文

posted @ 2008-08-09 17:05 J-Pei 阅读(2632) 评论(0) 推荐(0)

摘要:private DataGridView dataGridView1 = new DataGridView(); private void AddColorColumn() { DataGridViewComboBoxColumn comboBoxColumn = new DataGridViewComboBoxColumn(); comboBoxColumn.I... 阅读全文

posted @ 2008-08-09 11:16 J-Pei 阅读(701) 评论(0) 推荐(0)

摘要:private void dataGridView1_CellBeginEdit(object sender, DataGridViewCellCancelEventArgs e) { if (dataGridView1.Rows[e.RowIndex].Cells[e.ColumnIndex].GetType().Name == ... 阅读全文

posted @ 2008-08-05 12:49 J-Pei 阅读(181) 评论(0) 推荐(0)

导航