473,387 Members | 1,535 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

crystal report access database path problem

I am using access database to create a crystal report in VB.NET
Everything works fine when I run on my machine. But when I am
deploying it other windows machines. It is asking for database server
name and logon information. The problem which I understood from this
is that the path is hardcoded in the crystal report and the database
is in my bin folder. when I run my app on other machines it is looking
for the database in that folder and when it is not finding it, it is
prompting me to enter the database location.

Please help me how to get around this problem so that crystal report
can take database file from the application start up path rather than
hard-coding the path.

It is quite frustrating to know crystal reports hard codes the
database path
Nov 20 '05 #1
3 10981
I gave up on Crystal reports with this junk because of that issue, although
if you get the latest pack it may help you.
The thing is I didn't want to have to ship that big sucker for a little app.

I suggest getting the .NET resource kit for free and using the free
Component One Subscription and their reporting tool.

It is nice, simple and flexible.

Shane

"route_coder" <ca**@saai-svc.com> wrote in message
news:95**************************@posting.google.c om...
I am using access database to create a crystal report in VB.NET
Everything works fine when I run on my machine. But when I am
deploying it other windows machines. It is asking for database server
name and logon information. The problem which I understood from this
is that the path is hardcoded in the crystal report and the database
is in my bin folder. when I run my app on other machines it is looking
for the database in that folder and when it is not finding it, it is
prompting me to enter the database location.

Please help me how to get around this problem so that crystal report
can take database file from the application start up path rather than
hard-coding the path.

It is quite frustrating to know crystal reports hard codes the
database path

Nov 20 '05 #2
You will need to set the database location in code. Here is sample:

Dim logOnInfo As New TableLogOnInfo

' Set the connection information
OdbcConnection1.Open()
logOnInfo.ConnectionInfo.DatabaseName = OdbcConnection1.Database & ".mdb"
logOnInfo.ConnectionInfo.Password = "pwd"
OdbcConnection1.Close()

' Apply connection info. to every table in the report
For Each tbl As Table In rpt.Database.Tables
tbl.ApplyLogOnInfo(logOnInfo)
Next

"route_coder" wrote:
I am using access database to create a crystal report in VB.NET
Everything works fine when I run on my machine. But when I am
deploying it other windows machines. It is asking for database server
name and logon information. The problem which I understood from this
is that the path is hardcoded in the crystal report and the database
is in my bin folder. when I run my app on other machines it is looking
for the database in that folder and when it is not finding it, it is
prompting me to enter the database location.

Please help me how to get around this problem so that crystal report
can take database file from the application start up path rather than
hard-coding the path.

It is quite frustrating to know crystal reports hard codes the
database path

Nov 20 '05 #3
Thanks nina for your help.But I get the same database login error.
when i insert a report into a project, I create a standard report and
give the path of the database and there it is hardcoding the path.

I guess I will move to component one reporting tool and see whether it
works for me.
Thanks again

nina98765 <ni*******@discussions.microsoft.com> wrote in message news:<CB**********************************@microso ft.com>...
You will need to set the database location in code. Here is sample:

Dim logOnInfo As New TableLogOnInfo

' Set the connection information
OdbcConnection1.Open()
logOnInfo.ConnectionInfo.DatabaseName = OdbcConnection1.Database & ".mdb"
logOnInfo.ConnectionInfo.Password = "pwd"
OdbcConnection1.Close()

' Apply connection info. to every table in the report
For Each tbl As Table In rpt.Database.Tables
tbl.ApplyLogOnInfo(logOnInfo)
Next

"route_coder" wrote:
I am using access database to create a crystal report in VB.NET
Everything works fine when I run on my machine. But when I am
deploying it other windows machines. It is asking for database server
name and logon information. The problem which I understood from this
is that the path is hardcoded in the crystal report and the database
is in my bin folder. when I run my app on other machines it is looking
for the database in that folder and when it is not finding it, it is
prompting me to enter the database location.

Please help me how to get around this problem so that crystal report
can take database file from the application start up path rather than
hard-coding the path.

It is quite frustrating to know crystal reports hard codes the
database path

Nov 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: xtanto | last post by:
Hi All, We need to develope application & report that run on windows accessing Oracle on Linux. and we use Crystal Report as reporting tool. Can Crystal Report on windows access...
0
by: Sameer | last post by:
Hello I have a simple crystal report. Report is displayed using CrystalReportViewer control in a web form. It works fine. There is one problem with the database connection logic. Whenever I...
6
by: Chuck Yeager via DotNetMonster.com | last post by:
I think I am giong to die, this is driving us nuts. Here is the error we are getting when trying to use CrystalReportViewer: OS: XP SP1 and another machine XP SP2 (same errors) IDE: VS .NET...
0
by: Gurmukh | last post by:
Hello, We are working with VB.net and crystal reports with sql server2000 as database,the problem is that when we open a report and export it via default utility in crystal reports it works fine...
2
by: deegee | last post by:
hi, I'm trying to display a simple crystal report from within a web application but I keep getting prompted to enter login details for the database (oracle). Entering the correct information...
0
by: thomasma57 | last post by:
How do you connect an ADO control to an access database that has a password set. Using Jet.OLEBD. mike
4
by: MarkTingson | last post by:
Hi guys, Is there a way to prevent "Enter Parameter Values" message box to pop during VB6 program runtime?I have created a program in VB6 that uses a Crystal report control. When I put a...
0
by: Zuhaib Hyder | last post by:
i'm trying to configurer my dot net site on lcal IIS, which use ms access database while i try to access from other pc's, then database path error occurs, bcz my connection was trying to find...
6
by: praveenb000 | last post by:
we hosted a website http://vijayawadanalanda.org developed using asp.net and back end MS Accees database. There is some database connectivity problem occurring when saving the information in...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.