Refresh of frmInitial
This commit is contained in:
77
StockInfo/frmInitial.Designer.cs
generated
77
StockInfo/frmInitial.Designer.cs
generated
@ -37,8 +37,7 @@ namespace StockInfo
|
||||
this.btnBackupShares = new System.Windows.Forms.Button();
|
||||
this.btnReload = new System.Windows.Forms.Button();
|
||||
this.btnTestScrapFunction = new System.Windows.Forms.Button();
|
||||
this.lblStockRows = new System.Windows.Forms.Label();
|
||||
this.button1 = new System.Windows.Forms.Button();
|
||||
this.btnReloadShares = new System.Windows.Forms.Button();
|
||||
this.chbShowBrowser = new System.Windows.Forms.CheckBox();
|
||||
this.gbStockMgmnt = new System.Windows.Forms.GroupBox();
|
||||
this.btnStockSale = new System.Windows.Forms.Button();
|
||||
@ -46,6 +45,7 @@ namespace StockInfo
|
||||
this.btnStockReg = new System.Windows.Forms.Button();
|
||||
this.sfdSaver = new System.Windows.Forms.SaveFileDialog();
|
||||
this.ofdOpener = new System.Windows.Forms.OpenFileDialog();
|
||||
this.lblStockRows = new System.Windows.Forms.Label();
|
||||
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).BeginInit();
|
||||
this.gB1.SuspendLayout();
|
||||
this.gbStockMgmnt.SuspendLayout();
|
||||
@ -60,7 +60,7 @@ namespace StockInfo
|
||||
this.dataGridView.Location = new System.Drawing.Point(12, 16);
|
||||
this.dataGridView.Name = "dataGridView";
|
||||
this.dataGridView.RowTemplate.Height = 25;
|
||||
this.dataGridView.Size = new System.Drawing.Size(829, 363);
|
||||
this.dataGridView.Size = new System.Drawing.Size(829, 360);
|
||||
this.dataGridView.TabIndex = 0;
|
||||
//
|
||||
// lblTotalRecords
|
||||
@ -80,9 +80,9 @@ namespace StockInfo
|
||||
this.gB1.Controls.Add(this.btnRestoreShares);
|
||||
this.gB1.Controls.Add(this.btnBackupShares);
|
||||
this.gB1.Controls.Add(this.btnReload);
|
||||
this.gB1.Location = new System.Drawing.Point(157, 388);
|
||||
this.gB1.Location = new System.Drawing.Point(157, 385);
|
||||
this.gB1.Name = "gB1";
|
||||
this.gB1.Size = new System.Drawing.Size(264, 123);
|
||||
this.gB1.Size = new System.Drawing.Size(203, 144);
|
||||
this.gB1.TabIndex = 3;
|
||||
this.gB1.TabStop = false;
|
||||
this.gB1.Text = "Sharelist";
|
||||
@ -90,7 +90,7 @@ namespace StockInfo
|
||||
// chkEnableBackRes
|
||||
//
|
||||
this.chkEnableBackRes.AutoSize = true;
|
||||
this.chkEnableBackRes.Location = new System.Drawing.Point(7, 54);
|
||||
this.chkEnableBackRes.Location = new System.Drawing.Point(6, 61);
|
||||
this.chkEnableBackRes.Name = "chkEnableBackRes";
|
||||
this.chkEnableBackRes.Size = new System.Drawing.Size(144, 19);
|
||||
this.chkEnableBackRes.TabIndex = 5;
|
||||
@ -100,7 +100,7 @@ namespace StockInfo
|
||||
//
|
||||
// btnRestoreShares
|
||||
//
|
||||
this.btnRestoreShares.Location = new System.Drawing.Point(131, 84);
|
||||
this.btnRestoreShares.Location = new System.Drawing.Point(6, 111);
|
||||
this.btnRestoreShares.Name = "btnRestoreShares";
|
||||
this.btnRestoreShares.Size = new System.Drawing.Size(118, 23);
|
||||
this.btnRestoreShares.TabIndex = 4;
|
||||
@ -110,7 +110,7 @@ namespace StockInfo
|
||||
//
|
||||
// btnBackupShares
|
||||
//
|
||||
this.btnBackupShares.Location = new System.Drawing.Point(7, 84);
|
||||
this.btnBackupShares.Location = new System.Drawing.Point(6, 82);
|
||||
this.btnBackupShares.Name = "btnBackupShares";
|
||||
this.btnBackupShares.Size = new System.Drawing.Size(118, 23);
|
||||
this.btnBackupShares.TabIndex = 3;
|
||||
@ -121,7 +121,7 @@ namespace StockInfo
|
||||
// btnReload
|
||||
//
|
||||
this.btnReload.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.btnReload.Location = new System.Drawing.Point(6, 22);
|
||||
this.btnReload.Location = new System.Drawing.Point(6, 32);
|
||||
this.btnReload.Name = "btnReload";
|
||||
this.btnReload.Size = new System.Drawing.Size(112, 23);
|
||||
this.btnReload.TabIndex = 2;
|
||||
@ -132,7 +132,7 @@ namespace StockInfo
|
||||
// btnTestScrapFunction
|
||||
//
|
||||
this.btnTestScrapFunction.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.btnTestScrapFunction.Location = new System.Drawing.Point(12, 439);
|
||||
this.btnTestScrapFunction.Location = new System.Drawing.Point(12, 467);
|
||||
this.btnTestScrapFunction.Name = "btnTestScrapFunction";
|
||||
this.btnTestScrapFunction.Size = new System.Drawing.Size(75, 23);
|
||||
this.btnTestScrapFunction.TabIndex = 4;
|
||||
@ -140,31 +140,22 @@ namespace StockInfo
|
||||
this.btnTestScrapFunction.UseVisualStyleBackColor = true;
|
||||
this.btnTestScrapFunction.Click += new System.EventHandler(this.btnTestScrapFunction_Click);
|
||||
//
|
||||
// lblStockRows
|
||||
// btnReloadShares
|
||||
//
|
||||
this.lblStockRows.AutoSize = true;
|
||||
this.lblStockRows.Location = new System.Drawing.Point(93, 456);
|
||||
this.lblStockRows.Name = "lblStockRows";
|
||||
this.lblStockRows.Size = new System.Drawing.Size(14, 15);
|
||||
this.lblStockRows.TabIndex = 5;
|
||||
this.lblStockRows.Text = "#";
|
||||
//
|
||||
// button1
|
||||
//
|
||||
this.button1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.button1.Location = new System.Drawing.Point(12, 410);
|
||||
this.button1.Name = "button1";
|
||||
this.button1.Size = new System.Drawing.Size(75, 23);
|
||||
this.button1.TabIndex = 6;
|
||||
this.button1.Text = "ReLoad";
|
||||
this.button1.UseVisualStyleBackColor = true;
|
||||
this.button1.Click += new System.EventHandler(this.button1_Click);
|
||||
this.btnReloadShares.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.btnReloadShares.Location = new System.Drawing.Point(12, 417);
|
||||
this.btnReloadShares.Name = "btnReloadShares";
|
||||
this.btnReloadShares.Size = new System.Drawing.Size(75, 23);
|
||||
this.btnReloadShares.TabIndex = 6;
|
||||
this.btnReloadShares.Text = "ReLoad";
|
||||
this.btnReloadShares.UseVisualStyleBackColor = true;
|
||||
this.btnReloadShares.Click += new System.EventHandler(this.btnReloadShares_Click);
|
||||
//
|
||||
// chbShowBrowser
|
||||
//
|
||||
this.chbShowBrowser.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.chbShowBrowser.AutoSize = true;
|
||||
this.chbShowBrowser.Location = new System.Drawing.Point(12, 474);
|
||||
this.chbShowBrowser.Location = new System.Drawing.Point(12, 497);
|
||||
this.chbShowBrowser.Name = "chbShowBrowser";
|
||||
this.chbShowBrowser.Size = new System.Drawing.Size(100, 22);
|
||||
this.chbShowBrowser.TabIndex = 7;
|
||||
@ -178,9 +169,9 @@ namespace StockInfo
|
||||
this.gbStockMgmnt.Controls.Add(this.btnStockSale);
|
||||
this.gbStockMgmnt.Controls.Add(this.btnValueView);
|
||||
this.gbStockMgmnt.Controls.Add(this.btnStockReg);
|
||||
this.gbStockMgmnt.Location = new System.Drawing.Point(427, 388);
|
||||
this.gbStockMgmnt.Location = new System.Drawing.Point(366, 385);
|
||||
this.gbStockMgmnt.Name = "gbStockMgmnt";
|
||||
this.gbStockMgmnt.Size = new System.Drawing.Size(257, 123);
|
||||
this.gbStockMgmnt.Size = new System.Drawing.Size(216, 144);
|
||||
this.gbStockMgmnt.TabIndex = 8;
|
||||
this.gbStockMgmnt.TabStop = false;
|
||||
this.gbStockMgmnt.Text = "Working";
|
||||
@ -188,7 +179,7 @@ namespace StockInfo
|
||||
// btnStockSale
|
||||
//
|
||||
this.btnStockSale.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.btnStockSale.Location = new System.Drawing.Point(108, 22);
|
||||
this.btnStockSale.Location = new System.Drawing.Point(108, 82);
|
||||
this.btnStockSale.Name = "btnStockSale";
|
||||
this.btnStockSale.Size = new System.Drawing.Size(96, 23);
|
||||
this.btnStockSale.TabIndex = 2;
|
||||
@ -199,7 +190,7 @@ namespace StockInfo
|
||||
// btnValueView
|
||||
//
|
||||
this.btnValueView.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.btnValueView.Location = new System.Drawing.Point(7, 51);
|
||||
this.btnValueView.Location = new System.Drawing.Point(6, 32);
|
||||
this.btnValueView.Name = "btnValueView";
|
||||
this.btnValueView.Size = new System.Drawing.Size(95, 23);
|
||||
this.btnValueView.TabIndex = 1;
|
||||
@ -210,7 +201,7 @@ namespace StockInfo
|
||||
// btnStockReg
|
||||
//
|
||||
this.btnStockReg.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.btnStockReg.Location = new System.Drawing.Point(6, 22);
|
||||
this.btnStockReg.Location = new System.Drawing.Point(6, 82);
|
||||
this.btnStockReg.Name = "btnStockReg";
|
||||
this.btnStockReg.Size = new System.Drawing.Size(96, 23);
|
||||
this.btnStockReg.TabIndex = 0;
|
||||
@ -222,15 +213,23 @@ namespace StockInfo
|
||||
//
|
||||
this.ofdOpener.FileName = "openFileDialog1";
|
||||
//
|
||||
// lblStockRows
|
||||
//
|
||||
this.lblStockRows.AutoSize = true;
|
||||
this.lblStockRows.Location = new System.Drawing.Point(13, 446);
|
||||
this.lblStockRows.Name = "lblStockRows";
|
||||
this.lblStockRows.Size = new System.Drawing.Size(0, 15);
|
||||
this.lblStockRows.TabIndex = 9;
|
||||
//
|
||||
// frmInitial
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(853, 520);
|
||||
this.ClientSize = new System.Drawing.Size(853, 538);
|
||||
this.Controls.Add(this.lblStockRows);
|
||||
this.Controls.Add(this.gbStockMgmnt);
|
||||
this.Controls.Add(this.chbShowBrowser);
|
||||
this.Controls.Add(this.button1);
|
||||
this.Controls.Add(this.lblStockRows);
|
||||
this.Controls.Add(this.btnReloadShares);
|
||||
this.Controls.Add(this.btnTestScrapFunction);
|
||||
this.Controls.Add(this.gB1);
|
||||
this.Controls.Add(this.lblTotalRecords);
|
||||
@ -257,8 +256,7 @@ namespace StockInfo
|
||||
private System.Windows.Forms.GroupBox gB1;
|
||||
private System.Windows.Forms.Button btnReload;
|
||||
private System.Windows.Forms.Button btnTestScrapFunction;
|
||||
private System.Windows.Forms.Label lblStockRows;
|
||||
private System.Windows.Forms.Button button1;
|
||||
private System.Windows.Forms.Button btnReloadShares;
|
||||
private System.Windows.Forms.CheckBox chbShowBrowser;
|
||||
private System.Windows.Forms.GroupBox gbStockMgmnt;
|
||||
private System.Windows.Forms.Button btnStockReg;
|
||||
@ -269,6 +267,7 @@ namespace StockInfo
|
||||
private System.Windows.Forms.Button btnBackupShares;
|
||||
private System.Windows.Forms.SaveFileDialog sfdSaver;
|
||||
private System.Windows.Forms.OpenFileDialog ofdOpener;
|
||||
private System.Windows.Forms.Label lblStockRows;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -36,6 +36,7 @@ namespace StockInfo
|
||||
ReloadData();
|
||||
btnRestoreShares.Enabled = false;
|
||||
btnBackupShares.Enabled = false;
|
||||
btnReloadShares.Enabled = false;
|
||||
}
|
||||
|
||||
private void ReloadData()
|
||||
@ -57,6 +58,7 @@ namespace StockInfo
|
||||
_stockMarketRepository.LoadStockMarketList(chbShowBrowser.Checked);
|
||||
var stocklist = _stockMarketRepository.StockMarketList;
|
||||
lblStockRows.Text = stocklist.Count().ToString();
|
||||
btnReloadShares.Enabled = true;
|
||||
}
|
||||
|
||||
private void frmInitial_FormClosing(object sender, FormClosingEventArgs e)
|
||||
@ -64,7 +66,9 @@ namespace StockInfo
|
||||
_stockMarketRepository.Clean();
|
||||
}
|
||||
|
||||
private void button1_Click(object sender, EventArgs e)
|
||||
|
||||
|
||||
private void Button1reload()
|
||||
{
|
||||
lblStockRows.Text = "";
|
||||
_stockMarketRepository.RefreshMarketList();
|
||||
@ -147,5 +151,10 @@ namespace StockInfo
|
||||
_stockRepository.RestoreStockMembers(stockList);
|
||||
};
|
||||
}
|
||||
|
||||
private void btnReloadShares_Click(object sender, EventArgs e)
|
||||
{
|
||||
Button1reload();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user