using BBWY.Controls; using NPOI.SS.Formula.Functions; using System; using System.Collections.Generic; using System.Text; using System.Windows; using System.Windows.Controls; using System.Windows.Data; using System.Windows.Documents; using System.Windows.Input; using System.Windows.Media; using System.Windows.Media.Imaging; using System.Windows.Shapes; namespace BBWY.Client.Views.PackTask { /// /// SetCountWindow.xaml 的交互逻辑 /// public partial class SetCountWindow : BWindow { public SetCountWindow() { InitializeComponent(); this.WindowStartupLocation = WindowStartupLocation.CenterScreen; } /// /// 委托设置数量 /// public Action SetCount { get; set; } private void BButton_Click(object sender, RoutedEventArgs e) { try { var count = Convert.ToInt32(tbCount.Text); SetCount(count); this.Close(); } catch { MessageBox.Show("请输入数字!"); } } } }