Solved

"load report failed" VB.NET (2002) on deployment machine

Posted on 2004-08-17
25
555 Views
Last Modified: 2008-01-09
Hi,

I have written my first extensive VB.NET project and am now at the deployment stage. It all works except the crystal stuff, would you beleive it!
Here is the code that i use to instantiate and run the report.

                Dim repland As New crptProdListLand()
                fViewer.crvMain.ReportSource = repland
                repland.SetDataSource(dsRep)
                fViewer.Show()

When i try to run the report on a deployed machine i get the error (handled and msgboxed out) "Load report failed" ...and then a credentials box pops up.
On the Dev machine it all works fine, as things always do!

I have packaged up the project using VS.NET 2002.
I have included the merge modules for my version of vs.net (2002)
         http://support.businessobjects.com/communityCS/FilesAndUpdates/cr_net_mergemodules_en.zip.asp

and i have included the merge files that i have learnt are related to ADO.NET handling.
(http://www.experts-exchange.com/Databases/Crystal_Reports/Q_21088702.html)
         VC_CRT.msm
         VC_STL.msm

Any help is much appreciated!

Regards

DSE
0
Comment
Question by:DSE
  • 13
  • 12
25 Comments
 
LVL 10

Expert Comment

by:ebolek
ID: 11820408
Is your report crptProdListLand() embedded to the project. Check to see in the deployment package it exists.

Regards
Emre
0
 

Author Comment

by:DSE
ID: 11820470
buildaction = embedded resource
  (this is the dev project not the package project)

..........(btw this is CR.NET that is included with VS.NET 2002)
0
 

Author Comment

by:DSE
ID: 11820541
I also tried connecting to non embedded reports like this

            fViewer.crvMain.ReportSource = "C:\test.rpt"
0
 
LVL 10

Expert Comment

by:ebolek
ID: 11820575
no that is wrong. You load the report for that

Crystal Decisions.CrystalReports.engine.reportdocument myreport = new report1;
myreport.load(path);
crystalviewer1.reportsource = myreport;

this is how youload the report with the path with c#
0
 
LVL 10

Expert Comment

by:ebolek
ID: 11820581
so you say when you run the report on the development machine, it displays the report OK right?
0
 

Author Comment

by:DSE
ID: 11820612
ok...for vb.net i have translated that into this...

            Dim repland As New CrystalDecisions.CrystalReports.Engine.ReportDocument()
                repland.Load(Application.ExecutablePath & "\crptProdListLand.rpt")
                fViewer.crvMain.ReportSource = repland
                repland.SetDataSource(dsRep)


ill go try it now :o)

0
 

Author Comment

by:DSE
ID: 11820617
yes the development machine displays fine.
0
 
LVL 10

Expert Comment

by:ebolek
ID: 11820639
you dont need to set the datasource, what is dsrep. Is it a dataset? yOu set the report source of the viewer and report displays fine.
0
 

Author Comment

by:DSE
ID: 11820698
it does with the first method shown at the top....

but after just testing the line with <<<<  causes the "load report failed" error

           Dim repland As New CrystalDecisions.CrystalReports.Engine.ReportDocument()
                repland.Load(Application.ExecutablePath & "\crptProdListLand.rpt") <<<<<<<<<<<<<<<<<<<
                fViewer.crvMain.ReportSource = repland
                repland.SetDataSource(dsRep)

dsrep is a dataset yes, I have to pass this to the report as i do several operations with it before the report shows. This doesnt cause a problem on the dev machine.

Ive just remembered to mention. The report is built on a XML schema (XSD) - basically a field definition file.

DSE


0
 

Author Comment

by:DSE
ID: 11820708
thats a point thinking about it.... i havent included the XSD in the package... should i?
0
 
LVL 10

Expert Comment

by:ebolek
ID: 11820715
Dim repland As New CrystalDecisions.CrystalReports.Engine.ReportDocument()
                repland.Load(Application.ExecutablePath & "\crptProdListLand.rpt") <<<<<<<<<<<<<<<<<<<
  repland.SetDataSource(dsRep)
 fViewer.crvMain.ReportSource = repland

The order is wrong though. First you set the datasource of the report document then you set the reprot source of the viewer,
             
0
 
LVL 10

Expert Comment

by:ebolek
ID: 11820733
it could be there are merge modules for datasets, that you should put in the rpoject
0
What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

 
LVL 10

Expert Comment

by:ebolek
ID: 11820760
let me find you the deployment document that I use. it is pretty good.

go to business objects.com and find ths document

Crystal Reports 10 and .Net Application Deployment

Also be sure to put the license code in the setup project. Did you do that.
0
 

Author Comment

by:DSE
ID: 11820831
are you refering to this page?
 http://support.businessobjects.com/library/kbase/articles/c2013175.asp

about the license code ... i passed that hurdle a little earlier!

ill take a good look at the suggestion and get back to you.

Thx
0
 
LVL 10

Expert Comment

by:ebolek
ID: 11820983
search for this document : "crnet_deployment.doc".

Yours is good too though
0
 

Author Comment

by:DSE
ID: 11821178
i found crnet_deployment.pdf ... i'd already ran through it :o/ and all seems to be in order.

I will go through it again in the morning with a fresh head!

Will return tomorrow. Thx for your help today.

DSE
0
 
LVL 10

Expert Comment

by:ebolek
ID: 11821202
No problem. I had lots of problem when i first try to deploy my app too. I understand man

Regards
Emre
0
 

Author Comment

by:DSE
ID: 11830569
Ive been through crnet_deployment.pdf and everthing seems to be in order.
hmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm!
0
 
LVL 10

Expert Comment

by:ebolek
ID: 11830662
what about the license code, did you put that in the property of the app
0
 

Author Comment

by:DSE
ID: 11830793
ye thats sorted... that was the first hurdle i had to cross. The package wouldnt complie saysing something like "licenece key cannot be null"... so i registered and put it in. compiles ok now. So its not that...

0
 
LVL 10

Expert Comment

by:ebolek
ID: 11830835
I dont know man, maybe you are using the wrong merge modules. But you said you checked it. I dont know, I have done exactly what that document said andit worked for me. SOrry

Regards
Emre
0
 

Author Comment

by:DSE
ID: 11830847
ill start a new package project and see how that goes.

Ill shout back when i have a result either way.

Regards

DSE
0
 
LVL 10

Accepted Solution

by:
ebolek earned 500 total points
ID: 11830860
yes lets see how it goes from scratch
0
 
LVL 10

Expert Comment

by:ebolek
ID: 11841084
Glad to help. Sometimes it helps to start from stractch

Regards
emre
0
 

Author Comment

by:DSE
ID: 11841087
thx very much for your persistant help!

by redoing the package from scratch i seem to have avoided the error this time.

I only added the merge files for crystal this time... so its essentially a cr.net dependancies installer... all is good as i can just copy the bin from the dev to the deploy for now.

I will make a tidier package at a later date including the whole lot.

Thx again!

DSE
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

I hate sub reports and always consider them the last resort in any reporting solution.  The negative effect on performance and maintainability is just not worth the easy ride they give the report writer.  Nine times out of ten reporting requirements…
Hot fix for .Net Crystal Reports 10.2.3600.0 to fix problems with sub reports running on 64 bit operating systems ISSUE: Reports which contain subreports fail with error "Missing Parameter Value" DEPLOYMENT SERVER OS: Windows 2008 with 64 bi…
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now