I have a crystal report and I load that into a crystal report viewer.
This works great. But what do I do when the path of my database changes.
For my forms I do the following:
This works great for my form.Code:Dim strTextFileLocation As String = System.Windows.Forms.Application.StartupPath & "\Config.txt" Dim myConnection As New OleDb.OleDbConnection Public Sub FillDataset() myConnection.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & strDatabasePath Try 'Open connection myConnection.Open() lblDatabaseConnection.Text = "Database connectie is geslaagd." 'Close the connection to the database myConnection.Close() Catch ex As Exception lblDatabaseConnection.Text = "Database connectie is mislukt." End Try End Sub
But how do I appky this to the crystal reports??????
Please please help...




Reply With Quote