TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
dreid
NA
1
0
propagating changes with SqlCeDataAdapter?
Jun 6 2004 12:56 PM
Hi, I'm trying to simply update my database with changes that I make to my DataSets, and it doesn't seem to be working (specifically this delete attempt). I'm new to this class so I was hoping someone could point out any mistake in my code, or point me to a good tutorial on this topic. Thank you for your time. In the following code, I'm simply attempting to delete the first entry in my tblCustomer table. The change seems to be taking place in the dataset itself, but when I try to accept the changes and propagate the delete, the database does not reflect the delete. [code] SqlCeDataAdapter daTest = new SqlCeDataAdapter("Select * from tblCustomer", cnRoofWeb); DataSet dsTest = new DataSet(); DataTable dtTest = new DataTable("tblCustomer"); daTest.Fill(dsTest); dtTest = dsTest.Tables[0]; DataRow[] drRows = dtTest.Select("Id = 1"); dsTest.Tables[0].Rows.Remove(drRows[0]); dsTest.AcceptChanges(); [/code]
Reply
Answers (
0
)
how to change column headers in a datagrid?
SQL 6.5 and ASP.NET/IIS - SQL Server does not exist or access denied