Hi Doug,
I use the following routine from a menu option so my users can change the database connection.
Private Sub SetDatabaseConnection()
'-- Check security for this module
If Not CheckSecuritySecurityIsGranted("DatabaseConnection") Then
Exit Sub
End If
'-- Show the connection dialog and allow a connection to be selected
If MicroFour.StrataFrame.Data.ConnectionManager.ShowAvailableConnectionStrings() Then
'-- Since a connection was selected, then all of the existing dialogs need to be closed
' since their connection is established to the original source.
For Each loForm As Form In Me.MdiChildren
loForm.Close()
loForm.Dispose()
Next
'-- Force the connections to be reset
MicroFour.StrataFrame.Data.ConnectionManager.SetConnections()
End If
End Sub