Data not saved - 08-05-2006 , 02:32 PM
I beg your help with is issue, please, I have spent lots of time and
still do not know what I am doing wrong!
I try to show a list of countries and let the user edit/add items to
Do accomplish that, I have a Winform with a DataGridView and a
BindingNavigator. I also have the DataSet, the BindingSource and the
So far, I can see the countries that I have in the database but when I
try to edit/add items, they are kept in memory until I quit the app but
they are not saved in the database.
The BindingNavigator's Save button has the following statements:
Private Sub CountriesBindingNavigatorSaveItem_Click( .......)
I am sure that I am missing one step, but do not know how to tell the
app to store the in-memory data in the dabase. This should be probably
done when the user closes the form, should'nt it?
Any help will be very appeciated!
Re: Data not saved - 08-09-2006 , 04:14 AM
don't know if this can help but have you create a command builder
associate with yours DataAdapter ?
for example :
Dim myCommandBuilder as New OleDbCommandBuilder(CountriesTableAdapter)
I know that if this' not done, the update done nothing and no Exception
Xavier a écrit :
Re: Data not saved - 08-13-2006 , 03:38 PM
check the "copy to output directory" from your database file in your solution. If the "copy always" value, you will never get the added/edited registers the next time you open your app. Change this property to "copy if newer" and try again.
Sorry for my very poor english.
Martín (from argentina)
Posted via www.DotNetSlackers.com
|Thread Tools||Search this Thread|