| | |
| | | public SetTimeStepDlg() |
| | | { |
| | | InitializeComponent(); |
| | | this.IconOptions.Icon = IStation.WinFrmUI.Properties.Resources.App; |
| | | this.layoutControl1.SetupLayoutControl(); |
| | | IconOptions.Icon = IStation.WinFrmUI.Properties.Resources.App; |
| | | layoutControl1.SetupLayoutControl(); |
| | | } |
| | | |
| | | /// <summary> |
| | |
| | | /// </summary> |
| | | public void SetBindingData(int SortCode) |
| | | { |
| | | this.txtSortCode.EditValue = SortCode; |
| | | txtSortCode.EditValue = SortCode; |
| | | } |
| | | |
| | | //验证 |
| | | private bool Valid() |
| | | { |
| | | this.dxErrorProvider1.ClearErrors(); |
| | | if (string.IsNullOrEmpty(this.txtSortCode.Text.Trim())) |
| | | dxErrorProvider1.ClearErrors(); |
| | | if (string.IsNullOrEmpty(txtSortCode.Text.Trim())) |
| | | { |
| | | this.dxErrorProvider1.SetError(this.txtSortCode, "必填项"); |
| | | dxErrorProvider1.SetError(txtSortCode, "必填项"); |
| | | return false; |
| | | } |
| | | return true; |
| | |
| | | { |
| | | if (!Valid()) |
| | | return; |
| | | if (this.ReloadDataEvent != null) |
| | | if (ReloadDataEvent != null) |
| | | { |
| | | this.ReloadDataEvent.Invoke(int.Parse(this.txtSortCode.Text)); |
| | | ReloadDataEvent.Invoke(int.Parse(txtSortCode.Text)); |
| | | } |
| | | this.DialogResult = DialogResult.OK; |
| | | this.Close(); |
| | | DialogResult = DialogResult.OK; |
| | | Close(); |
| | | } |
| | | |
| | | } |