Exemple #1
0
 //Method to sync textboxes with new datagrid selection
 //Clear textboxes if there is no datagrid selection left
 private void InitItems()
 {
     try
     {
         ModuleCodeTextBox.Text = ApprovedSubscriptionsDataGrid[0, 0].Value.ToString();
         ModuleNameTextBox.Text = ApprovedSubscriptionsDataGrid[1, 1].Value.ToString();
     }
     catch
     {
         ModuleCodeTextBox.Clear();
         ModuleNameTextBox.Clear();
     }
 }
Exemple #2
0
 //Method to sync textboxes with datagrid cell selected
 private void ApprovedSubscriptionsDataGrid_CellContentClick(object sender, DataGridViewCellEventArgs e)
 {
     try
     {
         ModuleCodeTextBox.Text = ApprovedSubscriptionsDataGrid[0, e.RowIndex].Value.ToString();
         ModuleNameTextBox.Text = ApprovedSubscriptionsDataGrid[1, e.RowIndex].Value.ToString();
     }
     catch
     {
         ModuleCodeTextBox.Clear();
         ModuleNameTextBox.Clear();
     }
 }
Exemple #3
0
 //Method to sync textboxes with datagrid cells
 private void SubScriptionsOverviewDataGrid_CellContentClick(object sender, DataGridViewCellEventArgs e)
 {
     try
     {
         ModuleCodeTextBox.Text  = SubScriptionsOverviewDataGrid[0, e.RowIndex].Value.ToString();
         ModuleNameTextBox.Text  = SubScriptionsOverviewDataGrid[1, e.RowIndex].Value.ToString();
         ModuleNotesTextBox.Text = SubScriptionsOverviewDataGrid[5, e.RowIndex].Value.ToString();
     }
     catch
     {
         ModuleCodeTextBox.Clear();
         ModuleNameTextBox.Clear();
         ModuleNotesTextBox.Clear();
     }
 }
Exemple #4
0
 //Method to sync textboxes with new datagrid selection
 //Clear textboxes if there is no datagrid selection left
 private void InitItems()
 {
     try
     {
         ModuleCodeTextBox.Text  = SubScriptionsOverviewDataGrid[0, 0].Value.ToString();
         ModuleNameTextBox.Text  = SubScriptionsOverviewDataGrid[1, 1].Value.ToString();
         ModuleNotesTextBox.Text = SubScriptionsOverviewDataGrid[5, 5].Value.ToString();
     }
     catch
     {
         ModuleCodeTextBox.Clear();
         ModuleNameTextBox.Clear();
         ModuleNotesTextBox.Clear();
     }
 }