mSchmidt
asked on
Updating a Table on a remote server using a Dataset, cant get it working
This is the code iam trying to get to copy all data from one table and insert it in a remote server.
The data is filled into the dData dataSet just fine.. and the MessageBox pops up to .. however no data is written..
SqlConnection sCnxn = new SqlConnection("server=195. 69.130.88\ \SQLEXPRES S,1434;dat abase=task list;uid=s a;pwd=x7xv lwv1;");
sCnxn.Open();
DataSet dData = new DataSet();
SqlCeDataAdapter aDBs=new SqlCeDataAdapter("Select * from phoneLog", cnxn);
aDBs.Fill(dData);
SqlDataAdapter bDBs = new SqlDataAdapter("select * from phoneLog",sCnxn);
bDBs.Update(dData);
MessageBox.Show("Sync completed");
Can someone tell me what iam doing wrong ?
The data is filled into the dData dataSet just fine.. and the MessageBox pops up to .. however no data is written..
SqlConnection sCnxn = new SqlConnection("server=195.
sCnxn.Open();
DataSet dData = new DataSet();
SqlCeDataAdapter aDBs=new SqlCeDataAdapter("Select * from phoneLog", cnxn);
aDBs.Fill(dData);
SqlDataAdapter bDBs = new SqlDataAdapter("select * from phoneLog",sCnxn);
bDBs.Update(dData);
MessageBox.Show("Sync completed");
Can someone tell me what iam doing wrong ?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.