private void DeleteCustomer(DialogResult dialogResult) { if (dialogResult == DialogResult.Ok) { Task.Factory.StartNew(() => { CustomerAction.DeleteCustomers(this.DBConnectionString, this.Entity.InternalList.Where(x => x.IsSelected)); GetCustomerCollection(); ShowProgressBar = false; }); } else { ShowProgressBar = false; } }