Hi,

I'm just getting started with C# and Windows Forms and as a learning process i want to create a simple application that will display certain fields from a table in a DataGridView and the remaining fields in textboxes below the DataGridView. What i'm having a problem with is synchronizing the DataGridView and textboxes so that when i click on a row in the DataGridView the textboxes get updated. I'm just not sure where to get started with achieving this. I've read in the MSDN library about "Ensuring Multiple Controls Bound to the Same Data Source Remain Synchronized " and some information about the CurrencyManager class, change notification and stuff related to that but either i'm not understanding the examples or they are stopping short of actually showing how to synchronise the two. If i add a ListBox as a bound control then selecting an item from the ListBox does update the textbox. I now need to achieve the same for

This is what i have so far (lbvitals is the ListBox):

Code:
        public Form1()
        {
            InitializeComponent();

            SqlDataAdapter DataAdapter = new SqlDataAdapter(CommandString,ConnectionString);
            DataSet DataSet = new DataSet();

            DataAdapter.Fill(DataSet, "vitals");

            lbvitals.DataSource = DataSet;
            lbvitals.DisplayMember = "vitals.first_name";
            lbvitals.ValueMember = "vitals.first_name";

            dataGridView1.DataSource = DataSet.Tables["vitals"].DefaultView;

            textBox1.DataBindings.Add("Text", DataSet, "vitals.last_name");

            textBox1.ReadOnly = true;
        }
Thanks