/*Its the event handler for OnLoad of home page of InvestQ * where user's investment amount can be feeded or previous transaction can be searched*/ private void HomeForm_Load(object sender, EventArgs e) { principalInputTextBox.Focus(); displayButton.Enabled = false; if (SessionSum != null) { principalInputTextBox.Text = SessionSum; displayButton.Enabled = true; } SearchListView.Hide(); SearchButton.Enabled = false; clearSearchButton.Enabled = false; searchTextBox.Enabled = false; }
/*Its the event handler on Click of Clear button, which in turn clears * all the last search record and takes the application to Form On Load view*/ private void clearSearchButton_Click(object sender, EventArgs e) { SearchListView.Items.Clear(); SearchListView.Hide(); searchByEmaiRadiolButton.Enabled = true; searchByTrxnRadioButton.Enabled = true; searchByEmaiRadiolButton.Checked = false; searchByTrxnRadioButton.Checked = false; searchTextBox.Clear(); searchTextBox.Enabled = false; displayButton.Enabled = true; SearchButton.Enabled = false; principalInputTextBox.Enabled = true; }