using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using Mesnac.Action.Base; using System.Text; using System.Windows.Forms; namespace Mesnac.Action.Feeding.ProducingPlan { public partial class FrmBarcode : Form { public FrmBarcode() { InitializeComponent(); } #region 属性定义 /// /// 条码 /// public string Barcode { get { return this.txtBarcode.Text; } } #endregion #region 初始化界面文本 /// /// 初始化界面文本 /// public void InitUI() { this.Text = LanguageService.Instance.Read(130); this.label1.Text = LanguageService.Instance.Read(131); this.btnOK.Text = LanguageService.Instance.Read(18); this.btnCancel.Text = LanguageService.Instance.Read(19); } #endregion private void FrmBarcode_Load(object sender, EventArgs e) { this.InitUI(); } private void btnOK_Click(object sender, EventArgs e) { if (String.IsNullOrEmpty(this.txtBarcode.Text)) { string msg = LanguageService.Instance.Read(132); MessageBox.Show(msg, LanguageService.Instance.Read(1), MessageBoxButtons.OK, MessageBoxIcon.Warning); return; } this.DialogResult = System.Windows.Forms.DialogResult.OK; } } }