回复 5楼dqjia的帖子
这个需要通过代码自定义:
- public partial class Form1 : Form
- {
- public Form1()
- {
- InitializeComponent();
- this.c1FlexGrid1.KeyDown += new KeyEventHandler(c1FlexGrid1_KeyDown);
- this.c1FlexGrid1.KeyActionEnter = C1.Win.C1FlexGrid.KeyActionEnum.MoveAcross;
-
- }
- bool flag = false;
- void c1FlexGrid1_KeyDown(object sender, KeyEventArgs e)
- {
- if (e.KeyCode == Keys.Enter)
- {
- flag = true;
- }
- }
- private void c1FlexGrid1_RowColChange(object sender, EventArgs e)
- {
- if (flag==true)
- {
- if (this.c1FlexGrid1.Col == 2)
- {
- flag = false;
- this.c1FlexGrid1.Col = 3;
- }
- }
- }
- }
复制代码 |