hi,
we have access form front-end with access database as back-end that we converted to sql server back-end and having, I believe, connection error. this is the code where it's crashing at:
-------------------------------------------------------
Public Sub updateSiteDocs(siteID As Long, protID As Long, updateSiteMembersOnly As Boolean)
Dim rstDocs, rstEvents, rstSitePers, rstSiteDocs, rstDocList As DAO.Recordset
Dim query As String
Dim newDocID As Long
Dim docExists As Boolean
Dim tdf1, tdf2 As TableDef
Dim dbs As Database
Dim qdf As QueryDef
'On Error GoTo err_sub
Set dbs = CurrentDb()
Set tdf1 = dbs.TableDefs("DocEvents")
//below is the line that is crashing the app
Set rstEvents = tdf1.OpenRecordset(dbOpenTable)
Set tdf2 = dbs.TableDefs("Documents")
Set rstDocs = tdf2.OpenRecordset(dbOpenTable)
---------------------------------------------------------
can someone help please.
thanks in advance
we have access form front-end with access database as back-end that we converted to sql server back-end and having, I believe, connection error. this is the code where it's crashing at:
-------------------------------------------------------
Public Sub updateSiteDocs(siteID As Long, protID As Long, updateSiteMembersOnly As Boolean)
Dim rstDocs, rstEvents, rstSitePers, rstSiteDocs, rstDocList As DAO.Recordset
Dim query As String
Dim newDocID As Long
Dim docExists As Boolean
Dim tdf1, tdf2 As TableDef
Dim dbs As Database
Dim qdf As QueryDef
'On Error GoTo err_sub
Set dbs = CurrentDb()
Set tdf1 = dbs.TableDefs("DocEvents")
//below is the line that is crashing the app
Set rstEvents = tdf1.OpenRecordset(dbOpenTable)
Set tdf2 = dbs.TableDefs("Documents")
Set rstDocs = tdf2.OpenRecordset(dbOpenTable)
---------------------------------------------------------
can someone help please.
thanks in advance