Where I highlighted in red it is stopping and giving me Run-time error '3734':
The database has been placed in a state by user 'Admin' on machine 'blah' that prevents it from being opened or locked.
How do I make it so I can get into the current database? Is there a setting, I am using access 2010 at the moment.
Code:
If MsgBox("Do you want to update the selected file with Drop Inlet data?", vbOKCancel) = vbOK Then
Dim dbGIS As DAO.Database
Dim rstGIS As DAO.Recordset
Dim fldID_NAME As DAO.Field
Dim fldRIM_ELEV As DAO.Field
Dim fldDICOL As DAO.Field
Dim fldDIGL As DAO.Field
Dim fldDIGE As DAO.Field
Dim fldDID As DAO.Field
Set dbGIS = OpenDatabase(strInputFileName)
Set rstGIS = dbGIS.OpenRecordset("Storm_Net_Junctions")
Set fldID_NAME = rstGIS.Fields(19)
Set fldRIM_ELEV = rstGIS.Fields(12)
Set fldDICOL = rstGIS.Fields(15)
Set fldDIGL = rstGIS.Fields(16)
Set fldDIGE = rstGIS.Fields(17)
Set fldDID = rstGIS.Fields(18)
Dim cdb As DAO.Database
Dim crst As DAO.Recordset
Set cdb = CurrentDb()
Set crst = cdb.OpenRecordset("InspectionsDI")
' MsgBox "test"
crst.MoveFirst
rstGIS.MoveFirst
Do While Not rstGIS.EOF
Do While Not crst.EOF
If fldID_NAME = crst![Manhole Number (12)] Then
MsgBox crst![Manhole Number (12)]
Exit Do
End If
crst.MoveNext
Loop
rstGIS.MoveNext
Loop
End If