I have been using examples from the textbook creating a OleDbDataAdapter using the wizard, everything works fine loading the data into the dataset, but when i try to update the dataset, it doesn't save tod the database, can someone please tell me what im doing wrong: I created the data adapter and dataset using the wizard, I binded all applicable textboxes. I do not get any errors the update command just doesn't save to the Access Database.

This is my code

Imports System
Imports System.IO
Imports System.Data
Imports System.Data.OleDb

Public Class Form1
    Inherits System.Windows.Forms.Form

Private Sub Label3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Label3.Click

    End Sub

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

        OleDbDataAdapter1.Fill(DataSet11)

    End Sub

    Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
        OleDbDataAdapter1.Update(DataSet11)
    End Sub
End Class

Recommended Answers

All 3 Replies

Open app.config and change AttachDbFilename attribute value with absolute path of .mdb

where do i find app.config?

Well i created the app.config file but how exactly do i change that value.
the app.config file contains

<?xml version="1.0" encoding="utf-8"?>
<configuration>
	<appSettings>

	</appSettings>
</configuration>
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.