private void button_Click(object sender, RoutedEventArgs e) { if (!string.IsNullOrEmpty(textBox.Text) && string.IsNullOrEmpty(textBox1.Text)) { client.resaizeImage(id, Convert.ToInt32(textBox.Text), Convert.ToInt32(textBox1.Text)); } }