Click here to Skip to main content
15,913,610 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Dear expert
I have acess db which is in a Windows project. You know a dataset is created and components generated like table adapter dataset in toolbox this I have dragged to form and code like
Tableadaper1.fill(dataset.emp);

For insert
Tableadapter1.Insert(Id,nm);

This is shown on data grid on form while form load Nd insert
I have checked in access also data reaches in table.
I have done all this using ado command parameters etc earlier several times but this is first time I'm using the components which get created when u connect to db now if I change some code Nd debug it the data I inserted just goes Nd if I keep access open to see what happens

It shows #Error in the columns Nd data gets deleted. Sorry if some typos on a mobile phone. The data which is present earlier to the inclusion of access file remains intact.

Should I use ado cmd.param.adwitval stuff or can I save coding effort using this method only if data does not get deleted like a ghost
Posted

1 solution

According to your question, here you will find better solution, we are already have similar kind of problems however answers are also available try to search your self, finally you are not getting solution. Then ask,,,,happy coding

https://mdsaputra.wordpress.com/2012/01/13/step-by-step-connect-to-access-database-in-c-sharp/
 
Share this answer
 
v2
Comments
Mantu Singh 29-Mar-15 9:45am    
I have worked using ado.net code on several access based project but this time I plan to save coding by using components created by Vstodio and do in one line which manual coding requires10 lines. And this data deletion prob is quite nagging since morning then only I posted it
Anyway thanks for or help

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900