Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problems with Vb6.0&Crystalreports

Status
Not open for further replies.

hortensiam

IS-IT--Management
Feb 5, 2002
86
AR
Hi,
I use a CRViewer control in my VB6 application. When the user execute a crystal report (*.dsr) and later close it I supouse that the database , wich is linked to the report remain open because, later when i intend to repair it with the command
DBengine.repairdatabase ...
appear the following message:
error 3049 ..,can´t open the database because it is in use

When a Database is linked to a Crystal Report, close the report , close the database too!!!
Is this correct?
Thanks,
 
Hi, in the form that contains the CRViewer control type this:

Private Sub Form_Unload(Cancel As Integer)

' Where Report is the instance of the .dsr (report)
Set Report = Nothing

End Sub
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top