private void Button_Click(object sender, Windows.UI.Xaml.RoutedEventArgs e) { if (Stock.Text.Equals("") || Name.Text.Equals("")) { MessageDialog msg = new MessageDialog("Faltan Datos Por Completar"); msg.ShowAsync(); } else { var category = (Categories)comboList.SelectedItem; var supplier = (Suppliers)SuppliersCombo.SelectedItem; Products.AddData((App.Current as App).ConnectionString, category.Id, Int32.Parse(Stock.Text), Name.Text, Description.Text, supplier.Id, buffer); UpdateList(); EmptyBoxes(); } }