Skip to content

Commit c7f9d1e

Browse files
Close and shift-open database before merge
This helps a lot with making sure we don't have object references that could impact our ability to merge an existing object into the current database. (Otherwise you could have a loaded instance of a class that prevents the incoming object from properly importing.)
1 parent da1401a commit c7f9d1e

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

Version Control.accda.src/modules/modImportExport.bas

+8
Original file line numberDiff line numberDiff line change
@@ -739,6 +739,14 @@ Public Sub Build(strSourceFolder As String, blnFullBuild As Boolean, _
739739
RunSubInCurrentProject strText
740740
Perf.OperationEnd
741741
End If
742+
743+
' Now, just to make sure all objects are closed and unloaded, we will
744+
' close and shift-open the database before merging source files into it.
745+
Log.Add "Closing and reopening current database before merge..."
746+
Perf.OperationStart "Reopen DB before Merge"
747+
CloseCurrentDatabase2
748+
ShiftOpenDatabase strPath
749+
Perf.OperationEnd
742750
End If
743751

744752
' Start log and performance timers

0 commit comments

Comments
 (0)