Spawny
Jul 3rd, 2000, 05:56 AM
Hi,
I have the following code which opens a database when my application is first run:
Function OpenDataBase(ByVal pDatabasName As String) As Boolean
On Error GoTo OpenDataBaseError
Set pWorkspace = Workspaces(0)
Set pDatabase = pWorkspace.OpenDataBase(App.Path & "\" & pDatabasName, False, False)
OpenDataBase = True
End Function
This opens the database and I have no problems here. I then later wish to close the database for maintenance and know that the following line closes the database:
pdatabase.close
Now my Question is: How do I reopen the database without it getting upset with pworkspace or any other complications?
Any help is appreciated and thanks in advance.
Mike
I have the following code which opens a database when my application is first run:
Function OpenDataBase(ByVal pDatabasName As String) As Boolean
On Error GoTo OpenDataBaseError
Set pWorkspace = Workspaces(0)
Set pDatabase = pWorkspace.OpenDataBase(App.Path & "\" & pDatabasName, False, False)
OpenDataBase = True
End Function
This opens the database and I have no problems here. I then later wish to close the database for maintenance and know that the following line closes the database:
pdatabase.close
Now my Question is: How do I reopen the database without it getting upset with pworkspace or any other complications?
Any help is appreciated and thanks in advance.
Mike