日期:2014-05-17 浏览次数:21027 次
private void tabControl1_MouseMove(object sender, MouseEventArgs e) { for (int i = 0; i < tabControl1.TabPages.Count; i++) { Rectangle rect = tabControl1.GetTabRect(i); if (rect.Contains(e.Location)) { tabControl1.SelectedIndex = i; break; } } }