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!

error while calling report from vb

Status
Not open for further replies.

shahina

Programmer
Aug 19, 2003
47
IN
Hi all,

i have this problem..that i am using vb 6.0 and access and crystal reports. the report was working fine until i had made some modifications.. i have set the odbc connection and all..when i modified the report, the report is not printing from the vb form..i.e it's not going to the line crystalreport.printreport statement..when i opened the crystal report, each time when parameter value is given, it's telling that"c:\folder\databasename is not a valid path..Make sure that u r connected to the server on which the file resides". thing is it's not there in c:..it's in e:..earlier it was in c: in another machine..in this i have put in e: and set the odbc to e:\databasename. after this when i click ok, it's showing the logon server dialog box and i set the database as e:\databasename and clicked ok. then it's showing the preview..but from vb form it's not working..and once i close the report file from CR and open it again the same thing is coming again..i have to fill the database button of logon server dialog box..
i am not sure that i could make u understand my problem..hope u have got some idea atleast..can u please help me..it's urgent..please..
thanx in advance

shahina
 
The location is actually hard-coded in the report the first time you create it. You'll need to go to the database menu and set the new location to the e: drive. Then it should work.

Also, there's a way to change the server for each table in the report object from VB so it will work on any computer. See the crystal web site for how to do this - although I've never done it with an Access db, which I assume you're using.

"I think we're all Bozos on this bus!" - Firesign Theatre [jester]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top