Update data on parent form

Hi.

I have 4 tables in relationship. I have a parent form with a textboxes that display data from parent table (person), another textboxes that display data from foreign table (address) and 3 datagridview that display outher information from outhers tables. When I am filling text and pressing Save button (personTableAdapter.update(dataSet.person), only parent table are updated - When I am filling once again and saving, only parent table and table that are shown in datagridview are updated - I do not why the table binding to textbox are not updated. When I am swap textboxes to datagridview - it is working ... What is the problem?

Outher question.

I want using child form as a wizard to entry data to my database . I have tabcontrol with 4 tabpages represented each tables. When end user will fill person table data (parent table) than pressing next button, is going to tabpage2 and than to 3 and 4. At the finish I want to save everything to database.

I am using the code fromthispost...

AddFrm theAddForm = newAddFrm(theDataSet, who); //who is an index of tabcontrol

theAddForm.ShowDialog();

personBindingSource.DataSource = theDataSet.Tables["person"];

personDataAdapter.Update(theDataSet);

//Add form

..

//global variable

private DataSet theDataSet;

privateintwho;

..

Public theAddForm (DataSet theDs, int who )

{

this.theDataSet = theDs;

..

}

..

..

private next_button_Click(object sender, EventArgs e)

{

int i = tabControl1.SelectedIndex;

try

{

if (i == 0)

{

object[] personRecord =newobject[] { idTextBox.Text, f_nameTextBox.Text, nameTextBox.Text, dobDateTimePicker.Text, who};

this.therDataSet.Tables["person"].Rows.Add(personRecord);

if (i == 1)

{

object[] addressRecord =newobject[] { idTextBox.Text, zipTextBox.Text, countryTextBox.Text, houseTextBox.Text };

this.theDataSet.Relations["FK_address_person"].ChildTable.Rows.Add(addressRecord);

}

...

}

How can I update foreign tables?

Thanks

[3703 byte] By [TomaszK.] at [2007-12-25]
# 1

Any ideas ?

TomaszK. at 2007-9-3 > top of Msdn Tech,Visual Studio Express Editions,Visual C# 2005 Express Edition...