1 Attachment(s)
Cannot get oleAdapter to update Access
Been trying to make a Movie database that will be able to list, search and all that fun database stuff... But I ran in to a problem
Access DB w\ 2 Tables (Movies, Contacts)
Have a
OleConnection
OleDbDataAdapter
DSMovies1
Both Created w\ Server Explorer
Generated a DataSet from the adapter
On the form I have linked TextBoxs to the dataset thru DataBinding.
Pretty basic right...ok
Fill the dataset works great & it displays the data fine on the form thru the boxs. Can scroll thru the data just like in VB6 DAO tool , Using me.BindingContext etc...
Now my issue
Say I make a change to the textBox by changing the title of a Movie, CLick update
(oledbdataadapter.update(DSMovies1)
It makes the change on the from and if I scroll back & forth the change is there in Cache, When I look in the database in access no change, restart to program no change at all, SO I assumed it was the Update statement, so I changed it to
Update Movies
SET Title = ?, Etc
Where (MovieId = ?) (<-- Primary Key)
Then update nothing
so I thought the dataset wasn't updating , so I did
dsMovies1.AcceptChanges()
adapter.UpdateCommand = SQLStatement
adapter.Update(DsMovies1)
Nothing!!
Please Help, I have included The DB, frm & dataset