hello there,
I am looking for faster method to relink tables in my database project. i am attaching my code and i` need to modify it. i think TableDefs Append method is faster than DoCmd.TransferDatabase(which I am using in my code).

here is my code:

Function RelinkTables()

'************************************************* *****************************************
'This sub relinks the tables. It is assumed that the database is in the same folder as the
'application, so local distribution of the app is not being used.
'************************************************* *****************************************
On Error GoTo suberror

Dim dbMy As Database
Dim dbData As Database
Dim i As Integer
Dim strDataPath As String
Dim varReturn As Variant
Set dbMy = CurrentDb()
For i = 0 To dbMy.TableDefs.Count - 1
If dbMy.TableDefs(i).Name = "tblPeopleOrgs" Then
Exit Function
End If
Next i
strDataPath = PathFromString(CurrentDb().Name) & "ContactsData.mdb"
Set dbData = OpenDatabase(strDataPath)
varReturn = SysCmd(acSysCmdInitMeter, "Relinking tables...", dbData.TableDefs.Count)

DoCmd.SetWarnings False
For i = 0 To dbData.TableDefs.Count - 1
If (Left(dbData.TableDefs(i).Name, 4) <> "MSys") And (dbData.TableDefs(i).Properties("connect") = "") Then
DoCmd.TransferDatabase acLink, "Microsoft Access", strDataPath, , dbData.TableDefs(i).Name, dbData.TableDefs(i).Name
varReturn = SysCmd(acSysCmdUpdateMeter, i)
End If
Next i

varReturn = SysCmd(acSysCmdRemoveMeter)

Exit Function
Select Case Err
Case 2450
MsgBox "The application won't function without data tables.", , "RelinkTables"
Exit Function
Case 3024
DoCmd.OpenForm "dlgFindDataMDB", acNormal, , , acFormEdit, acDialog
strDataPath = Forms![dlgFindDataMDB]![txtDataFile]
Case Else
Call LogError("RelinkTables", Err.Number, Err.Description)
Call OpenErrorDialog("RelinkTables", Err.Number, Err.Description)
End Select

Exit Function
End Function