Issue #80: Fixed wrong condition on fetch first parameter in function Execute_TerminalInfoString

This commit is contained in:
vdemydiuk
2018-02-13 18:35:40 +02:00
parent 11fd5b7527
commit a238e5eb36
4 changed files with 36 additions and 0 deletions
+25
View File
@@ -210,6 +210,8 @@
this.button4 = new System.Windows.Forms.Button(); this.button4 = new System.Windows.Forms.Button();
this.tabPage11 = new System.Windows.Forms.TabPage(); this.tabPage11 = new System.Windows.Forms.TabPage();
this.button69 = new System.Windows.Forms.Button(); this.button69 = new System.Windows.Forms.Button();
this.button72 = new System.Windows.Forms.Button();
this.comboBox12 = new System.Windows.Forms.ComboBox();
this.groupBox1.SuspendLayout(); this.groupBox1.SuspendLayout();
this.statusStrip1.SuspendLayout(); this.statusStrip1.SuspendLayout();
this.groupBox2.SuspendLayout(); this.groupBox2.SuspendLayout();
@@ -1427,6 +1429,8 @@
// //
// tabPage4 // tabPage4
// //
this.tabPage4.Controls.Add(this.comboBox12);
this.tabPage4.Controls.Add(this.button72);
this.tabPage4.Controls.Add(this.button36); this.tabPage4.Controls.Add(this.button36);
this.tabPage4.Controls.Add(this.comboBox10); this.tabPage4.Controls.Add(this.comboBox10);
this.tabPage4.Controls.Add(this.comboBox9); this.tabPage4.Controls.Add(this.comboBox9);
@@ -2146,6 +2150,25 @@
this.button69.UseVisualStyleBackColor = true; this.button69.UseVisualStyleBackColor = true;
this.button69.Click += new System.EventHandler(this.button69_Click); this.button69.Click += new System.EventHandler(this.button69_Click);
// //
// button72
//
this.button72.Location = new System.Drawing.Point(208, 186);
this.button72.Name = "button72";
this.button72.Size = new System.Drawing.Size(111, 23);
this.button72.TabIndex = 37;
this.button72.Text = "TerminalInfoString";
this.button72.UseVisualStyleBackColor = true;
this.button72.Click += new System.EventHandler(this.button72_Click);
//
// comboBox12
//
this.comboBox12.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.comboBox12.FormattingEnabled = true;
this.comboBox12.Location = new System.Drawing.Point(13, 188);
this.comboBox12.Name = "comboBox12";
this.comboBox12.Size = new System.Drawing.Size(186, 21);
this.comboBox12.TabIndex = 38;
//
// Form1 // Form1
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
@@ -2379,6 +2402,8 @@
private System.Windows.Forms.TextBox textBoxAccountLogin; private System.Windows.Forms.TextBox textBoxAccountLogin;
private System.Windows.Forms.Button button70; private System.Windows.Forms.Button button70;
private System.Windows.Forms.Button button71; private System.Windows.Forms.Button button71;
private System.Windows.Forms.ComboBox comboBox12;
private System.Windows.Forms.Button button72;
} }
} }
+11
View File
@@ -34,6 +34,7 @@ namespace TestApiClientUI
comboBox9.DataSource = Enum.GetNames(typeof(EnumTerminalInfoInteger)); comboBox9.DataSource = Enum.GetNames(typeof(EnumTerminalInfoInteger));
comboBox10.DataSource = Enum.GetNames(typeof(EnumTerminalInfoDouble)); comboBox10.DataSource = Enum.GetNames(typeof(EnumTerminalInfoDouble));
comboBox11.DataSource = Enum.GetNames(typeof(EnumObject)); comboBox11.DataSource = Enum.GetNames(typeof(EnumObject));
comboBox12.DataSource = Enum.GetNames(typeof(ENUM_TERMINAL_INFO_STRING));
comboBoxAccountInfoCmd.DataSource = Enum.GetNames(typeof(TradeOperation)); comboBoxAccountInfoCmd.DataSource = Enum.GetNames(typeof(TradeOperation));
_apiClient.QuoteUpdated += apiClient_QuoteUpdated; _apiClient.QuoteUpdated += apiClient_QuoteUpdated;
@@ -1129,6 +1130,16 @@ namespace TestApiClientUI
PrintLog($"TerminalInfoDouble: result = {result}"); PrintLog($"TerminalInfoDouble: result = {result}");
} }
//TerminalInfoString
private async void button72_Click(object sender, EventArgs e)
{
ENUM_TERMINAL_INFO_STRING propId;
Enum.TryParse(comboBox12.Text, out propId);
var result = await Execute(() => _apiClient.TerminalInfoString(propId));
PrintLog($"TerminalInfoString: result = {result}");
}
private void checkBox2_CheckedChanged(object sender, EventArgs e) private void checkBox2_CheckedChanged(object sender, EventArgs e)
{ {
var checkbox = sender as CheckBox; var checkbox = sender as CheckBox;
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.