I have a stored Procedure in MS Access and it works in MS Access but when I call that Stored Procedure from a vb.net win form it returns
nothing in terms of Data. IN Access it looks like this
WHERE (((Global.LDAP) Like '*OU=NAZ*'));
The stored Procedure is called NAZUsers and data is from a LDAP Query that pulls every user in the Active Directory. I wanted to narrow data down to one OU (Organizational Unit) so that's what the Like statement is for
In vb.net a have a class
Public Function GetNazPeople() As DataTable
Dim con As New OleDbConnection(connectionString)
Dim cmd As New OleDbCommand("NAZUsers", con)
cmd.CommandType = CommandType.StoredProcedure
Dim adapter As New OleDbDataAdapter(cmd)
Dim ds As New DataSet()
' Set up a relation between these tables.
In the Win form
the call is DataGridView1.DataSource = Program.StoreDB.GetNazPeople
I'm using now Dim connectionString As String = "Provider=Microsoft.Jet.OLEDB.4.0;" & _
"Data Source=NazScheduler.mdb;" instead of accdb extension for Access 2010.
It's just this Stored Procedure that doesn't work called from VB.NET Win form My other stored Proceures
work outside of Access.