private void buttonRemove_Click(object sender, EventArgs e) { CoreWebService.CarTypeAttributeResponse response = client.deleteCarTypeAttribute(Convert.ToInt32(listBoxAttributes.SelectedValue)); if (response.Status == 0) { refreshAttributeListBox(); } }
private void buttonInsert_Click(object sender, EventArgs e) { if (textBoxAttribute.Text != null || textBoxAttribute.Text.Length > 0) { CoreWebService.CarTypeAttributeResponse response = client.addCarTypeAttribute(Convert.ToInt32(listBoxCarType.SelectedValue), textBoxAttribute.Text); if (response.Status == 0) { refreshAttributeListBox(); } else if (response.Status == 2) { MessageBox.Show(response.Message); } } }