i am trying to write a program for an estates agents. I have a table in access97 with the house details and i want to pick out certain houses. i am getting the run-time error 91 and dont know how to fix it.
Printable View
i am trying to write a program for an estates agents. I have a table in access97 with the house details and i want to pick out certain houses. i am getting the run-time error 91 and dont know how to fix it.
The Object variable or With block variable not set error could be caused by not creating an instance of the object you're referring to, i.e.Would fail.VB Code:
Dim oRs As ADODB.Recordset oRs.Open "SomeTable", "DSN=MYDSN;"OrVB Code:
Dim oRs As New ADODB.Recordset oRs.Open "SomeTable", "DSN=MYDSN;"Would Work.VB Code:
Dim oRs As ADODB.Recordset Set oRs = New ADODB.Recordset oRs.Open "SomeTable", "DSN=MYDSN;"