Beispiel #1
0
        protected void OnNeuronSelected(object sender, SelectedNeuronEventArgs e)
        {
            DataRow row = rowNeuronMap.Single(kvp => kvp.Value == e.Neuron).Key;

            // Find the row in the view.
            int idx         = 0;
            int selectedRow = 0;

            foreach (DataRowView drv in dvStudy)
            {
                // De-select all rows.
                dgvStudy.Rows[idx].Selected = false;

                if (drv.Row == row)
                {
                    selectedRow = idx;
                }

                ++idx;
            }

            // Select just the row associated with the neuron selected in the "chart."
            dgvStudy.Rows[selectedRow].Selected = true;
        }
Beispiel #2
0
		protected void OnNeuronSelected(object sender, SelectedNeuronEventArgs e)
		{
			DataRow row = rowNeuronMap.Single(kvp => kvp.Value == e.Neuron).Key;

			// Find the row in the view.
			int idx = 0;
			int selectedRow = 0;

			foreach (DataRowView drv in dvStudy)
			{
				// De-select all rows.
				dgvStudy.Rows[idx].Selected = false;

				if (drv.Row == row)
				{
					selectedRow = idx;
				}

				++idx;
			}

			// Select just the row associated with the neuron selected in the "chart."
			dgvStudy.Rows[selectedRow].Selected = true;
		}