This commit is contained in:
sc committed 2023-11-22 23:55:35 +08:00
commit bd64153d83
2 files changed
+15 -10

No files matched your search

+11 -10
View File
@@ -481,12 +481,12 @@ namespace formula_manage
{ {
if (e.Key == Key.Enter) if (e.Key == Key.Enter)
{ {
UserClass.PressKey.PressKeys(Keys.Right, false); PressKey.PressKeys(Keys.Right, false);
UserClass.PressKey.PressKeys(Keys.Right, true); PressKey.PressKeys(Keys.Right, true);
UserClass.PressKey.PressKeys(Keys.Up, false); PressKey.PressKeys(Keys.Up, false);
UserClass.PressKey.PressKeys(Keys.Up, true); PressKey.PressKeys(Keys.Up, true);
UserClass.PressKey.PressKeys(Keys.Tab, false); PressKey.PressKeys(Keys.Tab, false);
UserClass.PressKey.PressKeys(Keys.Tab, true); PressKey.PressKeys(Keys.Tab, true);
System.Windows.Controls.ComboBox curComboBox = sender as System.Windows.Controls.ComboBox; System.Windows.Controls.ComboBox curComboBox = sender as System.Windows.Controls.ComboBox;
curComboBox.SelectedIndex = 1; curComboBox.SelectedIndex = 1;
@@ -501,14 +501,15 @@ namespace formula_manage
{ {
if (e.Key == Key.Enter) if (e.Key == Key.Enter)
{ {
UserClass.PressKey.PressKeys(Keys.Left, false); PressKey.PressKeys(Keys.Left, false);
UserClass.PressKey.PressKeys(Keys.Left, true); PressKey.PressKeys(Keys.Left, true);
UserClass.PressKey.PressKeys(Keys.Tab, false); PressKey.PressKeys(Keys.Tab, false);
UserClass.PressKey.PressKeys(Keys.Tab, true); PressKey.PressKeys(Keys.Tab, true);
} }
} }
+4
View File
@@ -8,6 +8,10 @@ using System.Windows;
namespace formula_manage.UserClass namespace formula_manage.UserClass
{ {
/// <summary>
/// 实时更新datagrid
/// 调用示例:DataGridHelper.SetRealTimeCommit(Grid, true); Grid为对象控件名
/// </summary>
public static class DataGridHelper public static class DataGridHelper
{ {
public static void SetRealTimeCommit(DataGrid dataGrid, bool isRealTime) public static void SetRealTimeCommit(DataGrid dataGrid, bool isRealTime)