|
-
Jun 6th, 2008, 08:00 AM
#1
Thread Starter
Lively Member
[RESOLVED] Crystal Reports 2008, Access 2003, VS .NET 2008
Hi guys. The problem I am having is the following: I have an Access database, a bunch of forms and data sets which all work well. I have some Crystal Reports which work well during debug. After I make my installer, add everything needed and install on the client computer, run the app all works well in regards to the forms and the data seems to be going into the database. When I try to view the Crystal reports I get a database logon screen, the path it shows is on my developement computer and no security was selected for the database. How do I make the reports look for the newly created database? Should I use the datasets instead of the actual database? How would I do this? I have also noticed that if I try to add the report to the viewer via the report source box selecting an existing report I get an error that says that it was not found in the manifest and to rebuild and try again. If I browse to the file and add it that way I get no error, but when the app runs on the client computer it says that it failed to load. I tried the deployment forum and they said to come here for help. I hope I'm in the right place now. I am using VS 2008, an Access 2003 database and CR 2008.
-
Jun 8th, 2008, 11:41 AM
#2
Thread Starter
Lively Member
Re: Crystal Reports 2008, Access 2003, VS .NET 2008
Hi folks. Well, since no one could come up with an answer to my questions I got to thinking why this was occuring. After some investigation and reading I found out that Crystal Reports reports have a static connection to the data they report on. In my case, I was using an Access database. When my application would install on the target computer, everything would work except the reports that I made with CR. When I installed it on my developement computer they worked fine. This prompted the question: WHY!?
Well, come to find out, I had been developing the program in a folder on my desktop for easy access to it. The program installed and found the database on my desktop, which is where I had told it to look for the data. Makes sense. Anyway, I changed the name of the folder on the desktop, from let's say MyApp to MyApp1, and suddenly the reports did not work anymore. So i confirmed that the problem was in the connection string to the database. It took me a few days of searching and a lot of dead ends to come up with the solution to the problem which follows below.
The first thing you will need to do is create the msi. This is the Windows installer you can make with Visual Studio for your app. Second is to install it in it's default location. Once it is installed, reopen Visual Studio. You must then go and change where your reports get their data from to point to the default installation of your app. This is usually C drive, manufacturer, app name. Once you have done that, build your msi again, making sure that you dissable the option for selecting an install directory on the target computer. When your app installs on any target computer, the reports will work because they are already pointed in the right direction.
Keep in mind that this took a lot of thinking to come up with, considering CR states that if you change the directory of the source of your data, you must manually change it in the report. This is a way of doing that, except you only do it once. If you like this post, please rate it, if it helps you, please say so, and if you have any questions, post a reply. Thanks and have a nice day.
Last edited by captdylanhunt; Jun 8th, 2008 at 09:53 PM.
-
Jun 9th, 2008, 05:33 AM
#3
New Member
Re: [RESOLVED] Crystal Reports 2008, Access 2003, VS .NET 2008
sorry ,i didn't read the thread carefully
but i think this problem because you fix the path of database in report design so you can use ODBC connection (DNS) to don't fix the database path
thanks
-
Jun 9th, 2008, 06:33 AM
#4
Thread Starter
Lively Member
Re: [RESOLVED] Crystal Reports 2008, Access 2003, VS .NET 2008
According to CR, anytime the data source is moved, you must manually change that information in the report. When you design a report for a program that has it's own database installed with it on a client computer is when you would use this. If you design a report for a company whose data source remains in the same place, then you would not need to do this.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|