0

I'm using VS 2012 and coding a try/catch block in an MS Access database project, but VS says OleDbException is not defined (see line 3 in the code). Anyone know why? I got some of this code from here, and according to MSDN OleDbException is valid in vb.net

        Try
            data_adapter.Update(CType(binding_source.DataSource, DataTable))
        Catch ex As OleDbException
            MsgBox("ERROR:" & ex.Source & " " & ex.Message, MsgBoxStyle.OkOnly)
        End Try

Edited by Ancient Dragon

2
Contributors
4
Replies
11
Views
5 Years
Discussion Span
Last Post by Ancient Dragon
This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.