hello I want to save and retrieval a picture from access database and i have this code that i use it in my work but when i use it they tell me that the table that i look for does not exist and i used visual basic .net 2010 .please help me
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSave.Click
If Trim(txtFileName.Text) = "" Then Exit Sub
Dim br As New IO.BinaryReader(New IO.FileStream(txtFileName.Text, IO.FileMode.Open, IO.FileAccess.Read, IO.FileShare.Read))
Dim arr() As Byte = br.ReadBytes(br.BaseStream.Length)
Dim dt As DataTable = ds.Tables(0)
Dim row As DataRow = dt.NewRow
row.Item(0) = arr
row.Item(1) = TextBox1.Text
dt.Rows.Add(row)
ds.Tables.Clear()
ds.Tables.Add(dt)
da.Update(ds)
MsgBox("Image added successfully!!", MsgBoxStyle.Information)
End Sub