- 트레일링 매도 추가
This commit is contained in:
351
AutoSeller.Designer.cs
generated
351
AutoSeller.Designer.cs
generated
@@ -31,19 +31,26 @@
|
|||||||
this.materialTabSelector1 = new MaterialSkin.Controls.MaterialTabSelector();
|
this.materialTabSelector1 = new MaterialSkin.Controls.MaterialTabSelector();
|
||||||
this.materialTabControl1 = new MaterialSkin.Controls.MaterialTabControl();
|
this.materialTabControl1 = new MaterialSkin.Controls.MaterialTabControl();
|
||||||
this.tabPage1 = new System.Windows.Forms.TabPage();
|
this.tabPage1 = new System.Windows.Forms.TabPage();
|
||||||
|
this.btSell = new MaterialSkin.Controls.MaterialRaisedButton();
|
||||||
this.splitContainer2 = new System.Windows.Forms.SplitContainer();
|
this.splitContainer2 = new System.Windows.Forms.SplitContainer();
|
||||||
|
this.splitContainer1 = new System.Windows.Forms.SplitContainer();
|
||||||
|
this.tbLog = new System.Windows.Forms.RichTextBox();
|
||||||
this.btUpdate = new MaterialSkin.Controls.MaterialRaisedButton();
|
this.btUpdate = new MaterialSkin.Controls.MaterialRaisedButton();
|
||||||
this.btCybos = new MaterialSkin.Controls.MaterialRaisedButton();
|
this.btCybos = new MaterialSkin.Controls.MaterialRaisedButton();
|
||||||
this.tabPage2 = new System.Windows.Forms.TabPage();
|
this.tabPage2 = new System.Windows.Forms.TabPage();
|
||||||
this.cbAccount = new System.Windows.Forms.ComboBox();
|
this.materialLabel7 = new MaterialSkin.Controls.MaterialLabel();
|
||||||
this.tbSubAccount = new MaterialSkin.Controls.MaterialSingleLineTextField();
|
this.tbTrailingCnt = new MaterialSkin.Controls.MaterialSingleLineTextField();
|
||||||
this.btApply = new MaterialSkin.Controls.MaterialFlatButton();
|
this.materialLabel6 = new MaterialSkin.Controls.MaterialLabel();
|
||||||
this.materialLabel1 = new MaterialSkin.Controls.MaterialLabel();
|
this.tbTrailingP = new MaterialSkin.Controls.MaterialSingleLineTextField();
|
||||||
this.tbBidCount = new MaterialSkin.Controls.MaterialSingleLineTextField();
|
this.materialLabel5 = new MaterialSkin.Controls.MaterialLabel();
|
||||||
|
this.materialLabel4 = new MaterialSkin.Controls.MaterialLabel();
|
||||||
|
this.materialLabel3 = new MaterialSkin.Controls.MaterialLabel();
|
||||||
this.materialLabel2 = new MaterialSkin.Controls.MaterialLabel();
|
this.materialLabel2 = new MaterialSkin.Controls.MaterialLabel();
|
||||||
this.btSell = new MaterialSkin.Controls.MaterialRaisedButton();
|
this.tbBidCount = new MaterialSkin.Controls.MaterialSingleLineTextField();
|
||||||
this.splitContainer1 = new System.Windows.Forms.SplitContainer();
|
this.materialLabel1 = new MaterialSkin.Controls.MaterialLabel();
|
||||||
this.tbLog = new System.Windows.Forms.RichTextBox();
|
this.btApply = new MaterialSkin.Controls.MaterialFlatButton();
|
||||||
|
this.tbSubAccount = new MaterialSkin.Controls.MaterialSingleLineTextField();
|
||||||
|
this.cbAccount = new System.Windows.Forms.ComboBox();
|
||||||
this.lvItems = new AutoSellerNS.ListViewNF();
|
this.lvItems = new AutoSellerNS.ListViewNF();
|
||||||
this.chCode = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
this.chCode = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||||
this.chCodeName = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
this.chCodeName = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||||
@@ -61,18 +68,17 @@
|
|||||||
this.chAskCount = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
this.chAskCount = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||||
this.chCallPrice = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
this.chCallPrice = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||||
this.chBidCount = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
this.chBidCount = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||||
this.materialLabel3 = new MaterialSkin.Controls.MaterialLabel();
|
|
||||||
this.materialTabControl1.SuspendLayout();
|
this.materialTabControl1.SuspendLayout();
|
||||||
this.tabPage1.SuspendLayout();
|
this.tabPage1.SuspendLayout();
|
||||||
((System.ComponentModel.ISupportInitialize)(this.splitContainer2)).BeginInit();
|
((System.ComponentModel.ISupportInitialize)(this.splitContainer2)).BeginInit();
|
||||||
this.splitContainer2.Panel1.SuspendLayout();
|
this.splitContainer2.Panel1.SuspendLayout();
|
||||||
this.splitContainer2.Panel2.SuspendLayout();
|
this.splitContainer2.Panel2.SuspendLayout();
|
||||||
this.splitContainer2.SuspendLayout();
|
this.splitContainer2.SuspendLayout();
|
||||||
this.tabPage2.SuspendLayout();
|
|
||||||
((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit();
|
((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit();
|
||||||
this.splitContainer1.Panel1.SuspendLayout();
|
this.splitContainer1.Panel1.SuspendLayout();
|
||||||
this.splitContainer1.Panel2.SuspendLayout();
|
this.splitContainer1.Panel2.SuspendLayout();
|
||||||
this.splitContainer1.SuspendLayout();
|
this.splitContainer1.SuspendLayout();
|
||||||
|
this.tabPage2.SuspendLayout();
|
||||||
this.SuspendLayout();
|
this.SuspendLayout();
|
||||||
//
|
//
|
||||||
// materialTabSelector1
|
// materialTabSelector1
|
||||||
@@ -117,6 +123,20 @@
|
|||||||
this.tabPage1.Text = "Items";
|
this.tabPage1.Text = "Items";
|
||||||
this.tabPage1.UseVisualStyleBackColor = true;
|
this.tabPage1.UseVisualStyleBackColor = true;
|
||||||
//
|
//
|
||||||
|
// btSell
|
||||||
|
//
|
||||||
|
this.btSell.AutoSize = true;
|
||||||
|
this.btSell.Depth = 0;
|
||||||
|
this.btSell.Location = new System.Drawing.Point(148, 3);
|
||||||
|
this.btSell.MouseState = MaterialSkin.MouseState.HOVER;
|
||||||
|
this.btSell.Name = "btSell";
|
||||||
|
this.btSell.Primary = true;
|
||||||
|
this.btSell.Size = new System.Drawing.Size(68, 28);
|
||||||
|
this.btSell.TabIndex = 4;
|
||||||
|
this.btSell.Text = "Sell";
|
||||||
|
this.btSell.UseVisualStyleBackColor = true;
|
||||||
|
this.btSell.Click += new System.EventHandler(this.btSell_Click);
|
||||||
|
//
|
||||||
// splitContainer2
|
// splitContainer2
|
||||||
//
|
//
|
||||||
this.splitContainer2.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
this.splitContainer2.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
@@ -138,6 +158,33 @@
|
|||||||
this.splitContainer2.TabIndex = 2;
|
this.splitContainer2.TabIndex = 2;
|
||||||
this.splitContainer2.SizeChanged += new System.EventHandler(this.splitContainer2_SizeChanged);
|
this.splitContainer2.SizeChanged += new System.EventHandler(this.splitContainer2_SizeChanged);
|
||||||
//
|
//
|
||||||
|
// splitContainer1
|
||||||
|
//
|
||||||
|
this.splitContainer1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.splitContainer1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.splitContainer1.Name = "splitContainer1";
|
||||||
|
this.splitContainer1.Orientation = System.Windows.Forms.Orientation.Horizontal;
|
||||||
|
//
|
||||||
|
// splitContainer1.Panel1
|
||||||
|
//
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(this.lvItems);
|
||||||
|
//
|
||||||
|
// splitContainer1.Panel2
|
||||||
|
//
|
||||||
|
this.splitContainer1.Panel2.Controls.Add(this.tbLog);
|
||||||
|
this.splitContainer1.Size = new System.Drawing.Size(804, 508);
|
||||||
|
this.splitContainer1.SplitterDistance = 353;
|
||||||
|
this.splitContainer1.TabIndex = 1;
|
||||||
|
//
|
||||||
|
// tbLog
|
||||||
|
//
|
||||||
|
this.tbLog.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.tbLog.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.tbLog.Name = "tbLog";
|
||||||
|
this.tbLog.Size = new System.Drawing.Size(804, 151);
|
||||||
|
this.tbLog.TabIndex = 0;
|
||||||
|
this.tbLog.Text = "";
|
||||||
|
//
|
||||||
// btUpdate
|
// btUpdate
|
||||||
//
|
//
|
||||||
this.btUpdate.AutoSize = true;
|
this.btUpdate.AutoSize = true;
|
||||||
@@ -169,6 +216,12 @@
|
|||||||
// tabPage2
|
// tabPage2
|
||||||
//
|
//
|
||||||
this.tabPage2.BackColor = System.Drawing.Color.White;
|
this.tabPage2.BackColor = System.Drawing.Color.White;
|
||||||
|
this.tabPage2.Controls.Add(this.materialLabel7);
|
||||||
|
this.tabPage2.Controls.Add(this.tbTrailingCnt);
|
||||||
|
this.tabPage2.Controls.Add(this.materialLabel6);
|
||||||
|
this.tabPage2.Controls.Add(this.tbTrailingP);
|
||||||
|
this.tabPage2.Controls.Add(this.materialLabel5);
|
||||||
|
this.tabPage2.Controls.Add(this.materialLabel4);
|
||||||
this.tabPage2.Controls.Add(this.materialLabel3);
|
this.tabPage2.Controls.Add(this.materialLabel3);
|
||||||
this.tabPage2.Controls.Add(this.materialLabel2);
|
this.tabPage2.Controls.Add(this.materialLabel2);
|
||||||
this.tabPage2.Controls.Add(this.tbBidCount);
|
this.tabPage2.Controls.Add(this.tbBidCount);
|
||||||
@@ -183,29 +236,145 @@
|
|||||||
this.tabPage2.TabIndex = 1;
|
this.tabPage2.TabIndex = 1;
|
||||||
this.tabPage2.Text = "Preference";
|
this.tabPage2.Text = "Preference";
|
||||||
//
|
//
|
||||||
// cbAccount
|
// materialLabel7
|
||||||
//
|
//
|
||||||
this.cbAccount.FormattingEnabled = true;
|
this.materialLabel7.AutoSize = true;
|
||||||
this.cbAccount.Location = new System.Drawing.Point(25, 62);
|
this.materialLabel7.Depth = 0;
|
||||||
this.cbAccount.Name = "cbAccount";
|
this.materialLabel7.Font = new System.Drawing.Font("Microsoft Sans Serif", 11F);
|
||||||
this.cbAccount.Size = new System.Drawing.Size(121, 20);
|
this.materialLabel7.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(222)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))));
|
||||||
this.cbAccount.TabIndex = 0;
|
this.materialLabel7.Location = new System.Drawing.Point(224, 229);
|
||||||
|
this.materialLabel7.MouseState = MaterialSkin.MouseState.HOVER;
|
||||||
|
this.materialLabel7.Name = "materialLabel7";
|
||||||
|
this.materialLabel7.Size = new System.Drawing.Size(21, 18);
|
||||||
|
this.materialLabel7.TabIndex = 12;
|
||||||
|
this.materialLabel7.Text = "회";
|
||||||
//
|
//
|
||||||
// tbSubAccount
|
// tbTrailingCnt
|
||||||
//
|
//
|
||||||
this.tbSubAccount.Depth = 0;
|
this.tbTrailingCnt.Depth = 0;
|
||||||
this.tbSubAccount.Hint = "";
|
this.tbTrailingCnt.Hint = "";
|
||||||
this.tbSubAccount.Location = new System.Drawing.Point(154, 62);
|
this.tbTrailingCnt.Location = new System.Drawing.Point(188, 225);
|
||||||
this.tbSubAccount.MouseState = MaterialSkin.MouseState.HOVER;
|
this.tbTrailingCnt.MouseState = MaterialSkin.MouseState.HOVER;
|
||||||
this.tbSubAccount.Name = "tbSubAccount";
|
this.tbTrailingCnt.Name = "tbTrailingCnt";
|
||||||
this.tbSubAccount.PasswordChar = '\0';
|
this.tbTrailingCnt.PasswordChar = '\0';
|
||||||
this.tbSubAccount.SelectedText = "";
|
this.tbTrailingCnt.SelectedText = "";
|
||||||
this.tbSubAccount.SelectionLength = 0;
|
this.tbTrailingCnt.SelectionLength = 0;
|
||||||
this.tbSubAccount.SelectionStart = 0;
|
this.tbTrailingCnt.SelectionStart = 0;
|
||||||
this.tbSubAccount.Size = new System.Drawing.Size(25, 23);
|
this.tbTrailingCnt.Size = new System.Drawing.Size(30, 23);
|
||||||
this.tbSubAccount.TabIndex = 1;
|
this.tbTrailingCnt.TabIndex = 11;
|
||||||
this.tbSubAccount.Text = "10";
|
this.tbTrailingCnt.Text = "2";
|
||||||
this.tbSubAccount.UseSystemPasswordChar = false;
|
this.tbTrailingCnt.UseSystemPasswordChar = false;
|
||||||
|
//
|
||||||
|
// materialLabel6
|
||||||
|
//
|
||||||
|
this.materialLabel6.AutoSize = true;
|
||||||
|
this.materialLabel6.Depth = 0;
|
||||||
|
this.materialLabel6.Font = new System.Drawing.Font("Microsoft Sans Serif", 11F);
|
||||||
|
this.materialLabel6.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(222)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))));
|
||||||
|
this.materialLabel6.Location = new System.Drawing.Point(152, 229);
|
||||||
|
this.materialLabel6.MouseState = MaterialSkin.MouseState.HOVER;
|
||||||
|
this.materialLabel6.Name = "materialLabel6";
|
||||||
|
this.materialLabel6.Size = new System.Drawing.Size(21, 18);
|
||||||
|
this.materialLabel6.TabIndex = 10;
|
||||||
|
this.materialLabel6.Text = "%";
|
||||||
|
//
|
||||||
|
// tbTrailingP
|
||||||
|
//
|
||||||
|
this.tbTrailingP.Depth = 0;
|
||||||
|
this.tbTrailingP.Hint = "";
|
||||||
|
this.tbTrailingP.Location = new System.Drawing.Point(116, 225);
|
||||||
|
this.tbTrailingP.MouseState = MaterialSkin.MouseState.HOVER;
|
||||||
|
this.tbTrailingP.Name = "tbTrailingP";
|
||||||
|
this.tbTrailingP.PasswordChar = '\0';
|
||||||
|
this.tbTrailingP.SelectedText = "";
|
||||||
|
this.tbTrailingP.SelectionLength = 0;
|
||||||
|
this.tbTrailingP.SelectionStart = 0;
|
||||||
|
this.tbTrailingP.Size = new System.Drawing.Size(30, 23);
|
||||||
|
this.tbTrailingP.TabIndex = 9;
|
||||||
|
this.tbTrailingP.Text = "1.0";
|
||||||
|
this.tbTrailingP.UseSystemPasswordChar = false;
|
||||||
|
//
|
||||||
|
// materialLabel5
|
||||||
|
//
|
||||||
|
this.materialLabel5.AutoSize = true;
|
||||||
|
this.materialLabel5.Depth = 0;
|
||||||
|
this.materialLabel5.Font = new System.Drawing.Font("Microsoft Sans Serif", 11F);
|
||||||
|
this.materialLabel5.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(222)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))));
|
||||||
|
this.materialLabel5.Location = new System.Drawing.Point(25, 229);
|
||||||
|
this.materialLabel5.MouseState = MaterialSkin.MouseState.HOVER;
|
||||||
|
this.materialLabel5.Name = "materialLabel5";
|
||||||
|
this.materialLabel5.Size = new System.Drawing.Size(77, 18);
|
||||||
|
this.materialLabel5.TabIndex = 8;
|
||||||
|
this.materialLabel5.Text = "최고가 대비";
|
||||||
|
//
|
||||||
|
// materialLabel4
|
||||||
|
//
|
||||||
|
this.materialLabel4.AutoSize = true;
|
||||||
|
this.materialLabel4.Depth = 0;
|
||||||
|
this.materialLabel4.Font = new System.Drawing.Font("Microsoft Sans Serif", 11F);
|
||||||
|
this.materialLabel4.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(222)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))));
|
||||||
|
this.materialLabel4.Location = new System.Drawing.Point(25, 144);
|
||||||
|
this.materialLabel4.MouseState = MaterialSkin.MouseState.HOVER;
|
||||||
|
this.materialLabel4.Name = "materialLabel4";
|
||||||
|
this.materialLabel4.Size = new System.Drawing.Size(64, 18);
|
||||||
|
this.materialLabel4.TabIndex = 7;
|
||||||
|
this.materialLabel4.Text = "조건 횟수";
|
||||||
|
//
|
||||||
|
// materialLabel3
|
||||||
|
//
|
||||||
|
this.materialLabel3.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||||
|
this.materialLabel3.AutoSize = true;
|
||||||
|
this.materialLabel3.Depth = 0;
|
||||||
|
this.materialLabel3.Font = new System.Drawing.Font("Microsoft Sans Serif", 11F);
|
||||||
|
this.materialLabel3.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(222)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))));
|
||||||
|
this.materialLabel3.Location = new System.Drawing.Point(6, 524);
|
||||||
|
this.materialLabel3.MouseState = MaterialSkin.MouseState.HOVER;
|
||||||
|
this.materialLabel3.Name = "materialLabel3";
|
||||||
|
this.materialLabel3.Size = new System.Drawing.Size(162, 18);
|
||||||
|
this.materialLabel3.TabIndex = 6;
|
||||||
|
this.materialLabel3.Text = "Version : 2017.02.01.09";
|
||||||
|
//
|
||||||
|
// materialLabel2
|
||||||
|
//
|
||||||
|
this.materialLabel2.AutoSize = true;
|
||||||
|
this.materialLabel2.Depth = 0;
|
||||||
|
this.materialLabel2.Font = new System.Drawing.Font("Microsoft Sans Serif", 11F);
|
||||||
|
this.materialLabel2.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(222)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))));
|
||||||
|
this.materialLabel2.Location = new System.Drawing.Point(152, 148);
|
||||||
|
this.materialLabel2.MouseState = MaterialSkin.MouseState.HOVER;
|
||||||
|
this.materialLabel2.Name = "materialLabel2";
|
||||||
|
this.materialLabel2.Size = new System.Drawing.Size(21, 18);
|
||||||
|
this.materialLabel2.TabIndex = 5;
|
||||||
|
this.materialLabel2.Text = "회";
|
||||||
|
//
|
||||||
|
// tbBidCount
|
||||||
|
//
|
||||||
|
this.tbBidCount.Depth = 0;
|
||||||
|
this.tbBidCount.Hint = "";
|
||||||
|
this.tbBidCount.Location = new System.Drawing.Point(116, 144);
|
||||||
|
this.tbBidCount.MouseState = MaterialSkin.MouseState.HOVER;
|
||||||
|
this.tbBidCount.Name = "tbBidCount";
|
||||||
|
this.tbBidCount.PasswordChar = '\0';
|
||||||
|
this.tbBidCount.SelectedText = "";
|
||||||
|
this.tbBidCount.SelectionLength = 0;
|
||||||
|
this.tbBidCount.SelectionStart = 0;
|
||||||
|
this.tbBidCount.Size = new System.Drawing.Size(30, 23);
|
||||||
|
this.tbBidCount.TabIndex = 4;
|
||||||
|
this.tbBidCount.Text = "5";
|
||||||
|
this.tbBidCount.UseSystemPasswordChar = false;
|
||||||
|
//
|
||||||
|
// materialLabel1
|
||||||
|
//
|
||||||
|
this.materialLabel1.AutoSize = true;
|
||||||
|
this.materialLabel1.Depth = 0;
|
||||||
|
this.materialLabel1.Font = new System.Drawing.Font("Microsoft Sans Serif", 11F);
|
||||||
|
this.materialLabel1.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(222)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))));
|
||||||
|
this.materialLabel1.Location = new System.Drawing.Point(25, 29);
|
||||||
|
this.materialLabel1.MouseState = MaterialSkin.MouseState.HOVER;
|
||||||
|
this.materialLabel1.Name = "materialLabel1";
|
||||||
|
this.materialLabel1.Size = new System.Drawing.Size(62, 18);
|
||||||
|
this.materialLabel1.TabIndex = 3;
|
||||||
|
this.materialLabel1.Text = "Account";
|
||||||
//
|
//
|
||||||
// btApply
|
// btApply
|
||||||
//
|
//
|
||||||
@@ -225,88 +394,29 @@
|
|||||||
this.btApply.UseVisualStyleBackColor = true;
|
this.btApply.UseVisualStyleBackColor = true;
|
||||||
this.btApply.Click += new System.EventHandler(this.btApply_Click);
|
this.btApply.Click += new System.EventHandler(this.btApply_Click);
|
||||||
//
|
//
|
||||||
// materialLabel1
|
// tbSubAccount
|
||||||
//
|
//
|
||||||
this.materialLabel1.AutoSize = true;
|
this.tbSubAccount.Depth = 0;
|
||||||
this.materialLabel1.Depth = 0;
|
this.tbSubAccount.Hint = "";
|
||||||
this.materialLabel1.Font = new System.Drawing.Font("Microsoft Sans Serif", 11F);
|
this.tbSubAccount.Location = new System.Drawing.Point(154, 62);
|
||||||
this.materialLabel1.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(222)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))));
|
this.tbSubAccount.MouseState = MaterialSkin.MouseState.HOVER;
|
||||||
this.materialLabel1.Location = new System.Drawing.Point(25, 29);
|
this.tbSubAccount.Name = "tbSubAccount";
|
||||||
this.materialLabel1.MouseState = MaterialSkin.MouseState.HOVER;
|
this.tbSubAccount.PasswordChar = '\0';
|
||||||
this.materialLabel1.Name = "materialLabel1";
|
this.tbSubAccount.SelectedText = "";
|
||||||
this.materialLabel1.Size = new System.Drawing.Size(62, 18);
|
this.tbSubAccount.SelectionLength = 0;
|
||||||
this.materialLabel1.TabIndex = 3;
|
this.tbSubAccount.SelectionStart = 0;
|
||||||
this.materialLabel1.Text = "Account";
|
this.tbSubAccount.Size = new System.Drawing.Size(25, 23);
|
||||||
|
this.tbSubAccount.TabIndex = 1;
|
||||||
|
this.tbSubAccount.Text = "10";
|
||||||
|
this.tbSubAccount.UseSystemPasswordChar = false;
|
||||||
//
|
//
|
||||||
// tbBidCount
|
// cbAccount
|
||||||
//
|
//
|
||||||
this.tbBidCount.Depth = 0;
|
this.cbAccount.FormattingEnabled = true;
|
||||||
this.tbBidCount.Hint = "";
|
this.cbAccount.Location = new System.Drawing.Point(25, 62);
|
||||||
this.tbBidCount.Location = new System.Drawing.Point(116, 144);
|
this.cbAccount.Name = "cbAccount";
|
||||||
this.tbBidCount.MouseState = MaterialSkin.MouseState.HOVER;
|
this.cbAccount.Size = new System.Drawing.Size(121, 20);
|
||||||
this.tbBidCount.Name = "tbBidCount";
|
this.cbAccount.TabIndex = 0;
|
||||||
this.tbBidCount.PasswordChar = '\0';
|
|
||||||
this.tbBidCount.SelectedText = "";
|
|
||||||
this.tbBidCount.SelectionLength = 0;
|
|
||||||
this.tbBidCount.SelectionStart = 0;
|
|
||||||
this.tbBidCount.Size = new System.Drawing.Size(30, 23);
|
|
||||||
this.tbBidCount.TabIndex = 4;
|
|
||||||
this.tbBidCount.Text = "5";
|
|
||||||
this.tbBidCount.UseSystemPasswordChar = false;
|
|
||||||
//
|
|
||||||
// materialLabel2
|
|
||||||
//
|
|
||||||
this.materialLabel2.AutoSize = true;
|
|
||||||
this.materialLabel2.Depth = 0;
|
|
||||||
this.materialLabel2.Font = new System.Drawing.Font("Microsoft Sans Serif", 11F);
|
|
||||||
this.materialLabel2.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(222)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))));
|
|
||||||
this.materialLabel2.Location = new System.Drawing.Point(152, 148);
|
|
||||||
this.materialLabel2.MouseState = MaterialSkin.MouseState.HOVER;
|
|
||||||
this.materialLabel2.Name = "materialLabel2";
|
|
||||||
this.materialLabel2.Size = new System.Drawing.Size(21, 18);
|
|
||||||
this.materialLabel2.TabIndex = 5;
|
|
||||||
this.materialLabel2.Text = "회";
|
|
||||||
//
|
|
||||||
// btSell
|
|
||||||
//
|
|
||||||
this.btSell.AutoSize = true;
|
|
||||||
this.btSell.Depth = 0;
|
|
||||||
this.btSell.Location = new System.Drawing.Point(148, 3);
|
|
||||||
this.btSell.MouseState = MaterialSkin.MouseState.HOVER;
|
|
||||||
this.btSell.Name = "btSell";
|
|
||||||
this.btSell.Primary = true;
|
|
||||||
this.btSell.Size = new System.Drawing.Size(68, 28);
|
|
||||||
this.btSell.TabIndex = 4;
|
|
||||||
this.btSell.Text = "Sell";
|
|
||||||
this.btSell.UseVisualStyleBackColor = true;
|
|
||||||
this.btSell.Click += new System.EventHandler(this.btSell_Click);
|
|
||||||
//
|
|
||||||
// splitContainer1
|
|
||||||
//
|
|
||||||
this.splitContainer1.Dock = System.Windows.Forms.DockStyle.Fill;
|
|
||||||
this.splitContainer1.Location = new System.Drawing.Point(0, 0);
|
|
||||||
this.splitContainer1.Name = "splitContainer1";
|
|
||||||
this.splitContainer1.Orientation = System.Windows.Forms.Orientation.Horizontal;
|
|
||||||
//
|
|
||||||
// splitContainer1.Panel1
|
|
||||||
//
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(this.lvItems);
|
|
||||||
//
|
|
||||||
// splitContainer1.Panel2
|
|
||||||
//
|
|
||||||
this.splitContainer1.Panel2.Controls.Add(this.tbLog);
|
|
||||||
this.splitContainer1.Size = new System.Drawing.Size(804, 508);
|
|
||||||
this.splitContainer1.SplitterDistance = 353;
|
|
||||||
this.splitContainer1.TabIndex = 1;
|
|
||||||
//
|
|
||||||
// tbLog
|
|
||||||
//
|
|
||||||
this.tbLog.Dock = System.Windows.Forms.DockStyle.Fill;
|
|
||||||
this.tbLog.Location = new System.Drawing.Point(0, 0);
|
|
||||||
this.tbLog.Name = "tbLog";
|
|
||||||
this.tbLog.Size = new System.Drawing.Size(804, 151);
|
|
||||||
this.tbLog.TabIndex = 0;
|
|
||||||
this.tbLog.Text = "";
|
|
||||||
//
|
//
|
||||||
// lvItems
|
// lvItems
|
||||||
//
|
//
|
||||||
@@ -432,19 +542,6 @@
|
|||||||
this.chBidCount.TextAlign = System.Windows.Forms.HorizontalAlignment.Right;
|
this.chBidCount.TextAlign = System.Windows.Forms.HorizontalAlignment.Right;
|
||||||
this.chBidCount.Width = 75;
|
this.chBidCount.Width = 75;
|
||||||
//
|
//
|
||||||
// materialLabel3
|
|
||||||
//
|
|
||||||
this.materialLabel3.AutoSize = true;
|
|
||||||
this.materialLabel3.Depth = 0;
|
|
||||||
this.materialLabel3.Font = new System.Drawing.Font("Roboto", 11F);
|
|
||||||
this.materialLabel3.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(222)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))));
|
|
||||||
this.materialLabel3.Location = new System.Drawing.Point(6, 524);
|
|
||||||
this.materialLabel3.MouseState = MaterialSkin.MouseState.HOVER;
|
|
||||||
this.materialLabel3.Name = "materialLabel3";
|
|
||||||
this.materialLabel3.Size = new System.Drawing.Size(165, 19);
|
|
||||||
this.materialLabel3.TabIndex = 6;
|
|
||||||
this.materialLabel3.Text = "Version : 2017.01.26.14";
|
|
||||||
//
|
|
||||||
// AutoSeller
|
// AutoSeller
|
||||||
//
|
//
|
||||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
|
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
|
||||||
@@ -461,12 +558,12 @@
|
|||||||
this.splitContainer2.Panel2.ResumeLayout(false);
|
this.splitContainer2.Panel2.ResumeLayout(false);
|
||||||
((System.ComponentModel.ISupportInitialize)(this.splitContainer2)).EndInit();
|
((System.ComponentModel.ISupportInitialize)(this.splitContainer2)).EndInit();
|
||||||
this.splitContainer2.ResumeLayout(false);
|
this.splitContainer2.ResumeLayout(false);
|
||||||
this.tabPage2.ResumeLayout(false);
|
|
||||||
this.tabPage2.PerformLayout();
|
|
||||||
this.splitContainer1.Panel1.ResumeLayout(false);
|
this.splitContainer1.Panel1.ResumeLayout(false);
|
||||||
this.splitContainer1.Panel2.ResumeLayout(false);
|
this.splitContainer1.Panel2.ResumeLayout(false);
|
||||||
((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).EndInit();
|
((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).EndInit();
|
||||||
this.splitContainer1.ResumeLayout(false);
|
this.splitContainer1.ResumeLayout(false);
|
||||||
|
this.tabPage2.ResumeLayout(false);
|
||||||
|
this.tabPage2.PerformLayout();
|
||||||
this.ResumeLayout(false);
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -506,5 +603,11 @@
|
|||||||
private System.Windows.Forms.ColumnHeader chMaxPrice;
|
private System.Windows.Forms.ColumnHeader chMaxPrice;
|
||||||
private System.Windows.Forms.ColumnHeader chCheckCount;
|
private System.Windows.Forms.ColumnHeader chCheckCount;
|
||||||
private MaterialSkin.Controls.MaterialLabel materialLabel3;
|
private MaterialSkin.Controls.MaterialLabel materialLabel3;
|
||||||
|
private MaterialSkin.Controls.MaterialLabel materialLabel7;
|
||||||
|
private MaterialSkin.Controls.MaterialSingleLineTextField tbTrailingCnt;
|
||||||
|
private MaterialSkin.Controls.MaterialLabel materialLabel6;
|
||||||
|
private MaterialSkin.Controls.MaterialSingleLineTextField tbTrailingP;
|
||||||
|
private MaterialSkin.Controls.MaterialLabel materialLabel5;
|
||||||
|
private MaterialSkin.Controls.MaterialLabel materialLabel4;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -65,6 +65,12 @@ namespace AutoSellerNS
|
|||||||
lvCurPrice.Items[10].SubItems[chAskCount.Index].Text = "현재가";
|
lvCurPrice.Items[10].SubItems[chAskCount.Index].Text = "현재가";
|
||||||
lvCurPrice.Items[10].SubItems[chCallPrice.Index].Font = new Font(lvCurPrice.Items[0].SubItems[0].Font, FontStyle.Bold);
|
lvCurPrice.Items[10].SubItems[chCallPrice.Index].Font = new Font(lvCurPrice.Items[0].SubItems[0].Font, FontStyle.Bold);
|
||||||
|
|
||||||
|
cbAccount.Text = Config.GetAccount();
|
||||||
|
tbSubAccount.Text = Config.GetSubAccount();
|
||||||
|
tbBidCount.Text = Config.GetBidCount().ToString();
|
||||||
|
tbTrailingP.Text = Config.GetTrailingRate().ToString();
|
||||||
|
tbTrailingCnt.Text = Config.GetTrailingCnt().ToString();
|
||||||
|
|
||||||
m_CybosHelper = new CybosHelper(this);
|
m_CybosHelper = new CybosHelper(this);
|
||||||
|
|
||||||
m_iCurPricePanelWith = splitContainer2.Panel2.Width;
|
m_iCurPricePanelWith = splitContainer2.Panel2.Width;
|
||||||
@@ -115,6 +121,8 @@ namespace AutoSellerNS
|
|||||||
|
|
||||||
if(lvItems.InvokeRequired)
|
if(lvItems.InvokeRequired)
|
||||||
{
|
{
|
||||||
|
CybosHelper.STOCK_CUR_ITEM ItemCur = m_CybosHelper.GetItem(Item.m_strCode);
|
||||||
|
|
||||||
lvItems.Invoke(new Action(() => {
|
lvItems.Invoke(new Action(() => {
|
||||||
lvItems.Items.Add(new ListViewItem(new string[] {
|
lvItems.Items.Add(new ListViewItem(new string[] {
|
||||||
Item.m_strCode,
|
Item.m_strCode,
|
||||||
@@ -126,8 +134,8 @@ namespace AutoSellerNS
|
|||||||
string.Format("{0:n0}", Item.m_iAssessedValue),
|
string.Format("{0:n0}", Item.m_iAssessedValue),
|
||||||
string.Format("{0:n0}", Item.m_iValuationGains),
|
string.Format("{0:n0}", Item.m_iValuationGains),
|
||||||
string.Format("{0:n2}", Item.m_dYield),
|
string.Format("{0:n2}", Item.m_dYield),
|
||||||
"",
|
ItemCur != null ? string.Format("{0:n0}", ItemCur.m_iMaxPrice) : "",
|
||||||
"",
|
ItemCur != null ? string.Format("{0:n0}", ItemCur.m_iCheckCount) : "",
|
||||||
}));
|
}));
|
||||||
|
|
||||||
var listviewItem = lvItems.Items[lvItems.Items.Count - 1];
|
var listviewItem = lvItems.Items[lvItems.Items.Count - 1];
|
||||||
@@ -141,6 +149,8 @@ namespace AutoSellerNS
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
CybosHelper.STOCK_CUR_ITEM ItemCur = m_CybosHelper.GetItem(Item.m_strCode);
|
||||||
|
|
||||||
lvItems.Items.Add(new ListViewItem(new string[] {
|
lvItems.Items.Add(new ListViewItem(new string[] {
|
||||||
Item.m_strCode,
|
Item.m_strCode,
|
||||||
Item.m_strCodeName,
|
Item.m_strCodeName,
|
||||||
@@ -151,10 +161,12 @@ namespace AutoSellerNS
|
|||||||
string.Format("{0:n0}", Item.m_iAssessedValue),
|
string.Format("{0:n0}", Item.m_iAssessedValue),
|
||||||
string.Format("{0:n0}", Item.m_iValuationGains),
|
string.Format("{0:n0}", Item.m_iValuationGains),
|
||||||
string.Format("{0:n2}", Item.m_dYield),
|
string.Format("{0:n2}", Item.m_dYield),
|
||||||
"",
|
ItemCur != null ? string.Format("{0:n0}", ItemCur.m_iMaxPrice) : "",
|
||||||
"",
|
ItemCur != null ? string.Format("{0:n0}", ItemCur.m_iCheckCount) : "",
|
||||||
}));
|
}));
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
var listviewItem = lvItems.Items[lvItems.Items.Count - 1];
|
var listviewItem = lvItems.Items[lvItems.Items.Count - 1];
|
||||||
|
|
||||||
lvItems.Items[lvItems.Items.Count - 1].UseItemStyleForSubItems = false;
|
lvItems.Items[lvItems.Items.Count - 1].UseItemStyleForSubItems = false;
|
||||||
@@ -262,7 +274,7 @@ namespace AutoSellerNS
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void OnReceivedCall(string strCode, int[] aiBidPrice, int[] aiBidCount, int[] aiAskPrice, int[] aiAskCount)
|
public void OnReceivedCall(string strCode, int iCurPrice, int[] aiBidPrice, int[] aiBidCount, int[] aiAskPrice, int[] aiAskCount)
|
||||||
{
|
{
|
||||||
if (strCode != m_strSelectedCode)
|
if (strCode != m_strSelectedCode)
|
||||||
return;
|
return;
|
||||||
@@ -274,6 +286,10 @@ namespace AutoSellerNS
|
|||||||
if (lvCurPrice.InvokeRequired)
|
if (lvCurPrice.InvokeRequired)
|
||||||
{
|
{
|
||||||
lvCurPrice.Invoke(new Action(() => {
|
lvCurPrice.Invoke(new Action(() => {
|
||||||
|
|
||||||
|
if(iCurPrice > 0)
|
||||||
|
lvCurPrice.Items[10].SubItems[chCallPrice.Index].Text = string.Format("{0:n0}", iCurPrice);
|
||||||
|
|
||||||
for (int i = 0; i < 10; i++)
|
for (int i = 0; i < 10; i++)
|
||||||
{
|
{
|
||||||
lvCurPrice.Items[i].SubItems[chAskCount.Index].Text = string.Format("{0:n0}", aiAskCount[9-i]);
|
lvCurPrice.Items[i].SubItems[chAskCount.Index].Text = string.Format("{0:n0}", aiAskCount[9-i]);
|
||||||
@@ -289,6 +305,9 @@ namespace AutoSellerNS
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
if(iCurPrice > 0)
|
||||||
|
lvCurPrice.Items[10].SubItems[chCallPrice.Index].Text = string.Format("{0:n0}", iCurPrice);
|
||||||
|
|
||||||
for (int i = 0; i < 10; i++)
|
for (int i = 0; i < 10; i++)
|
||||||
{
|
{
|
||||||
lvCurPrice.Items[i].SubItems[chAskCount.Index].Text = string.Format("{0:n0}", aiAskCount[9-i]);
|
lvCurPrice.Items[i].SubItems[chAskCount.Index].Text = string.Format("{0:n0}", aiAskCount[9-i]);
|
||||||
@@ -323,7 +342,7 @@ namespace AutoSellerNS
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
m_strSelectedCode = strCode;
|
m_strSelectedCode = strCode;
|
||||||
OnReceivedCall(strCode, Item.m_aiBidPrice, Item.m_aiBidCount, Item.m_aiAskPrice, Item.m_aiAskCount);
|
OnReceivedCall(strCode, Item.m_iCurPrice, Item.m_aiBidPrice, Item.m_aiBidCount, Item.m_aiAskPrice, Item.m_aiAskCount);
|
||||||
//OnReceivedCurPrice(strCode, Item.m_iCurPrice);
|
//OnReceivedCurPrice(strCode, Item.m_iCurPrice);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -336,6 +355,12 @@ namespace AutoSellerNS
|
|||||||
int iBidCount = 0;
|
int iBidCount = 0;
|
||||||
int.TryParse(tbBidCount.Text, out iBidCount);
|
int.TryParse(tbBidCount.Text, out iBidCount);
|
||||||
Config.SetBidCount(iBidCount);
|
Config.SetBidCount(iBidCount);
|
||||||
|
|
||||||
|
float fTrailingPercent = 0;
|
||||||
|
float.TryParse(tbTrailingP.Text, out fTrailingPercent);
|
||||||
|
int iTrailingCnt = 0;
|
||||||
|
int.TryParse(tbTrailingCnt.Text, out iTrailingCnt);
|
||||||
|
Config.SetTrailing(fTrailingPercent, iTrailingCnt);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
40
Config.cs
40
Config.cs
@@ -10,7 +10,7 @@ namespace AutoSellerNS
|
|||||||
{
|
{
|
||||||
static class Config
|
static class Config
|
||||||
{
|
{
|
||||||
static Dictionary<string, string> m_Data = new Dictionary<string, string>();
|
static Dictionary<string, object> m_Data = new Dictionary<string, object>();
|
||||||
|
|
||||||
static Random m_Random = new Random();
|
static Random m_Random = new Random();
|
||||||
|
|
||||||
@@ -18,7 +18,9 @@ namespace AutoSellerNS
|
|||||||
{
|
{
|
||||||
m_Data.Add("account", "");
|
m_Data.Add("account", "");
|
||||||
m_Data.Add("sub-account", "");
|
m_Data.Add("sub-account", "");
|
||||||
m_Data.Add("bid-count", "5");
|
m_Data.Add("bid-count", 5);
|
||||||
|
m_Data.Add("trailing-rate", 1.0f);
|
||||||
|
m_Data.Add("trailing-count", 2);
|
||||||
|
|
||||||
Load();
|
Load();
|
||||||
}
|
}
|
||||||
@@ -40,7 +42,7 @@ namespace AutoSellerNS
|
|||||||
continue;
|
continue;
|
||||||
|
|
||||||
if(m_Data.ContainsKey(aTokens[0]) == true)
|
if(m_Data.ContainsKey(aTokens[0]) == true)
|
||||||
m_Data[aTokens[0]] = aTokens[1];
|
m_Data[aTokens[0]] = Convert.ChangeType(aTokens[1], m_Data[aTokens[0]].GetType());
|
||||||
else
|
else
|
||||||
m_Data.Add(aTokens[0], aTokens[1]);
|
m_Data.Add(aTokens[0], aTokens[1]);
|
||||||
}
|
}
|
||||||
@@ -49,8 +51,8 @@ namespace AutoSellerNS
|
|||||||
static void Save()
|
static void Save()
|
||||||
{
|
{
|
||||||
string strContents = "";
|
string strContents = "";
|
||||||
foreach(KeyValuePair<string, string> pair in m_Data)
|
foreach(KeyValuePair<string, object> pair in m_Data)
|
||||||
strContents += pair.Key + "=" + pair.Value + Environment.NewLine;
|
strContents += pair.Key + "=" + pair.Value.ToString() + Environment.NewLine;
|
||||||
|
|
||||||
string strPath = Util.GetConfigPath()+"/config.ini";
|
string strPath = Util.GetConfigPath()+"/config.ini";
|
||||||
File.WriteAllText(strPath, strContents, new UTF8Encoding(true));
|
File.WriteAllText(strPath, strContents, new UTF8Encoding(true));
|
||||||
@@ -58,6 +60,7 @@ namespace AutoSellerNS
|
|||||||
|
|
||||||
public static void SetAccount(string strAccount, string strAccountSub)
|
public static void SetAccount(string strAccount, string strAccountSub)
|
||||||
{
|
{
|
||||||
|
if(strAccount != null)
|
||||||
m_Data["account"] = strAccount;
|
m_Data["account"] = strAccount;
|
||||||
m_Data["sub-account"] = strAccountSub;
|
m_Data["sub-account"] = strAccountSub;
|
||||||
Save();
|
Save();
|
||||||
@@ -65,25 +68,40 @@ namespace AutoSellerNS
|
|||||||
|
|
||||||
public static string GetAccount()
|
public static string GetAccount()
|
||||||
{
|
{
|
||||||
return m_Data["account"];
|
return (string)m_Data["account"];
|
||||||
}
|
}
|
||||||
|
|
||||||
public static string GetSubAccount()
|
public static string GetSubAccount()
|
||||||
{
|
{
|
||||||
return m_Data["sub-account"];
|
return (string)m_Data["sub-account"];
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void SetBidCount(int iCount)
|
public static void SetBidCount(int iCount)
|
||||||
{
|
{
|
||||||
m_Data["bid-count"] = iCount.ToString();
|
m_Data["bid-count"] = iCount;
|
||||||
Save();
|
Save();
|
||||||
}
|
}
|
||||||
|
|
||||||
public static int GetBidCount()
|
public static int GetBidCount()
|
||||||
{
|
{
|
||||||
int iCount = 0;
|
return (int)m_Data["bid-count"];
|
||||||
int.TryParse(m_Data["bid-count"], out iCount);
|
}
|
||||||
return iCount;
|
|
||||||
|
public static void SetTrailing(float fTrailingRate, int iTrailingCnt)
|
||||||
|
{
|
||||||
|
m_Data["trailing-rate"] = fTrailingRate;
|
||||||
|
m_Data["trailing-count"] = iTrailingCnt;
|
||||||
|
Save();
|
||||||
|
}
|
||||||
|
|
||||||
|
public static float GetTrailingRate()
|
||||||
|
{
|
||||||
|
return (float)m_Data["trailing-rate"];
|
||||||
|
}
|
||||||
|
|
||||||
|
public static int GetTrailingCnt()
|
||||||
|
{
|
||||||
|
return (int)m_Data["trailing-count"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ namespace AutoSellerNS
|
|||||||
public AutoSeller m_Listener = null;
|
public AutoSeller m_Listener = null;
|
||||||
public CybosHelper m_CybosHelper = null;
|
public CybosHelper m_CybosHelper = null;
|
||||||
public string m_strCode;
|
public string m_strCode;
|
||||||
|
public string m_strCodeName;
|
||||||
public DSCBO1Lib.StockCur m_StockCur = null;
|
public DSCBO1Lib.StockCur m_StockCur = null;
|
||||||
public DSCBO1Lib.StockJpbid m_Jpbid = null;
|
public DSCBO1Lib.StockJpbid m_Jpbid = null;
|
||||||
public int[] m_aiBidPrice = new int[10];
|
public int[] m_aiBidPrice = new int[10];
|
||||||
@@ -24,9 +25,14 @@ namespace AutoSellerNS
|
|||||||
public int m_iMaxPrice = 0;
|
public int m_iMaxPrice = 0;
|
||||||
public int m_iCheckCount = 0;
|
public int m_iCheckCount = 0;
|
||||||
|
|
||||||
|
public int m_iTrailingCount = 0;
|
||||||
|
|
||||||
public void OnRecievedPrice()
|
public void OnRecievedPrice()
|
||||||
{
|
{
|
||||||
m_iCurPrice = m_StockCur.GetHeaderValue(13);
|
m_iCurPrice = m_StockCur.GetHeaderValue(13);
|
||||||
|
if(m_iCurPrice > m_iMaxPrice)
|
||||||
|
m_iTrailingCount = 0;
|
||||||
|
|
||||||
m_iMaxPrice = Math.Max(m_iCurPrice, m_iMaxPrice);
|
m_iMaxPrice = Math.Max(m_iCurPrice, m_iMaxPrice);
|
||||||
|
|
||||||
int iAskPrice = m_StockCur.GetHeaderValue(7);
|
int iAskPrice = m_StockCur.GetHeaderValue(7);
|
||||||
@@ -36,8 +42,19 @@ namespace AutoSellerNS
|
|||||||
else
|
else
|
||||||
m_iCheckCount = 0;
|
m_iCheckCount = 0;
|
||||||
|
|
||||||
if (m_iCheckCount >= Config.GetBidCount() && m_Listener.IsSelling() == true)
|
if(m_iCheckCount >= Config.GetBidCount() && m_Listener.IsSelling() == true)
|
||||||
|
{
|
||||||
m_CybosHelper.SellItem(m_strCode, m_iCurPrice, m_Listener.GetSellableCount(m_strCode));
|
m_CybosHelper.SellItem(m_strCode, m_iCurPrice, m_Listener.GetSellableCount(m_strCode));
|
||||||
|
Util.Log(Util.LOG_TYPE.SELL, string.Format("[조건 완료 매도] {0} ({1}회)", m_strCodeName, Config.GetBidCount()));
|
||||||
|
}
|
||||||
|
|
||||||
|
if(m_iCurPrice < (m_iMaxPrice*(100.0f-Config.GetTrailingRate())/100.0f))
|
||||||
|
m_iTrailingCount++;
|
||||||
|
if(m_iTrailingCount >= Config.GetTrailingCnt() && m_Listener.IsSelling() == true)
|
||||||
|
{
|
||||||
|
m_CybosHelper.SellItem(m_strCode, m_iCurPrice, m_Listener.GetSellableCount(m_strCode));
|
||||||
|
Util.Log(Util.LOG_TYPE.SELL, string.Format("[트레일링 매도] {0} ({1}% {2}회)", m_strCodeName, Config.GetTrailingRate(), Config.GetTrailingCnt()));
|
||||||
|
}
|
||||||
|
|
||||||
m_Listener.OnReceivedCurPrice(m_strCode, m_iCurPrice, m_iMaxPrice, m_iCheckCount);
|
m_Listener.OnReceivedCurPrice(m_strCode, m_iCurPrice, m_iMaxPrice, m_iCheckCount);
|
||||||
}
|
}
|
||||||
@@ -60,7 +77,7 @@ namespace AutoSellerNS
|
|||||||
m_aiAskCount[i+5] = m_Jpbid.GetHeaderValue(29 + 4*i);
|
m_aiAskCount[i+5] = m_Jpbid.GetHeaderValue(29 + 4*i);
|
||||||
}
|
}
|
||||||
|
|
||||||
m_Listener.OnReceivedCall(m_strCode, m_aiBidPrice, m_aiBidCount, m_aiAskPrice, m_aiAskCount);
|
m_Listener.OnReceivedCall(m_strCode, 0, m_aiBidPrice, m_aiBidCount, m_aiAskPrice, m_aiAskCount);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -128,6 +145,8 @@ namespace AutoSellerNS
|
|||||||
AutoSeller.ITEM Item = new AutoSeller.ITEM();
|
AutoSeller.ITEM Item = new AutoSeller.ITEM();
|
||||||
|
|
||||||
Item.m_strCodeName = m_6033.GetDataValue(0, i);
|
Item.m_strCodeName = m_6033.GetDataValue(0, i);
|
||||||
|
if(Item.m_strCodeName != "")
|
||||||
|
{
|
||||||
Item.m_strCode = m_6033.GetDataValue(12, i);
|
Item.m_strCode = m_6033.GetDataValue(12, i);
|
||||||
Item.m_iItemCnt = m_6033.GetDataValue(7, i);
|
Item.m_iItemCnt = m_6033.GetDataValue(7, i);
|
||||||
Item.m_iAssessedValue = m_6033.GetDataValue(9, i);
|
Item.m_iAssessedValue = m_6033.GetDataValue(9, i);
|
||||||
@@ -138,12 +157,13 @@ namespace AutoSellerNS
|
|||||||
Item.m_iProfitUnitPrice = m_6033.GetDataValue(18, i);
|
Item.m_iProfitUnitPrice = m_6033.GetDataValue(18, i);
|
||||||
Item.m_iSellableCnt = m_6033.GetDataValue(15, i);
|
Item.m_iSellableCnt = m_6033.GetDataValue(15, i);
|
||||||
|
|
||||||
if (strCodeList.Length > 0)
|
if(strCodeList.Length > 0)
|
||||||
strCodeList += ",";
|
strCodeList += ",";
|
||||||
strCodeList += Item.m_strCode;
|
strCodeList += Item.m_strCode;
|
||||||
|
|
||||||
aItems.Add(Item);
|
aItems.Add(Item);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (strCodeList.Length > 0)
|
if (strCodeList.Length > 0)
|
||||||
{
|
{
|
||||||
@@ -161,6 +181,20 @@ namespace AutoSellerNS
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// sync
|
||||||
|
List<string> aRemoveKeys = new List<string>();
|
||||||
|
foreach(var Item in m_aStockCur)
|
||||||
|
{
|
||||||
|
if(aItems.Any(s => s.m_strCode == Item.Key) == false)
|
||||||
|
aRemoveKeys.Add(Item.Key);
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach(var Key in aRemoveKeys)
|
||||||
|
{
|
||||||
|
m_aStockCur[Key].m_StockCur.Unsubscribe();
|
||||||
|
m_aStockCur[Key].m_Jpbid.Unsubscribe();
|
||||||
|
m_aStockCur.Remove(Key);
|
||||||
|
}
|
||||||
|
|
||||||
return aItems;
|
return aItems;
|
||||||
}
|
}
|
||||||
@@ -238,6 +272,7 @@ namespace AutoSellerNS
|
|||||||
StockCur.m_Listener = m_Listener;
|
StockCur.m_Listener = m_Listener;
|
||||||
StockCur.m_CybosHelper = this;
|
StockCur.m_CybosHelper = this;
|
||||||
StockCur.m_strCode = Item.m_strCode;
|
StockCur.m_strCode = Item.m_strCode;
|
||||||
|
StockCur.m_strCodeName = Item.m_strCodeName;
|
||||||
StockCur.m_StockCur = new DSCBO1Lib.StockCur();
|
StockCur.m_StockCur = new DSCBO1Lib.StockCur();
|
||||||
StockCur.m_StockCur.SetInputValue(0, Item.m_strCode);
|
StockCur.m_StockCur.SetInputValue(0, Item.m_strCode);
|
||||||
StockCur.m_StockCur.Received += StockCur.OnRecievedPrice;
|
StockCur.m_StockCur.Received += StockCur.OnRecievedPrice;
|
||||||
|
|||||||
Reference in New Issue
Block a user