private void createClientBtn_Click(object sender, EventArgs e) { if (this.client != null) { this.client.Close(); } this.client = new SnowServiceClient(this.endpointUrlTxt.Text); if (!string.IsNullOrEmpty(this.apiKeyTxt.Text)) { this.client.ApiKey = this.apiKeyTxt.Text; } }