I am trying to write an app on vb.net. I am using visual studio community 2013. In some point I have to create mdb file. I searched all over internet and try every suggestions but always I get error on adox as follows (marked with *)

Namespace ADOX
Class Catalog

    Sub Create(sCreateString As String)
       ***Throw New NotImplementedException***
    End Sub

End Class
End Namespace

my script quite long but this is what I use for create mdb file

    Option Explicit On
    Imports System.Data.OleDb
    Imports System.IO
    Imports System.Linq
    Imports System.Data.SqlClient
    Imports ADOX


    Public Sub MakeADataBase(ByVal sDBName As String)
            Dim catArch = New ADOX.Catalog
            catArch.Create("Provider=Microsoft.Jet.OLEDB.4.0;" & _
                    "Data Source=" & sDBName & ";" & _
                    "Jet OLEDB:Engine Type=5")
            catArch = Nothing
    End Sub

this code is working on new project but not working on my original project and always generate above error. What could be the problem?


The mostly likely reason for this failure is that you're developing the program as a 64-bit application. The Jet OLEDB driver is 32-bit only.

So, from visual studio, just use the "Configuration Manager" to change the "platform" to x86.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.