Solved

Crystal Reports viewers virtual directory

Posted on 2009-05-15
5
537 Views
Last Modified: 2012-05-07
I am developing a ASP.net web app that runs crystal reports and shows them in a cr web viewer.

This working ok so far in the development environment.

I am trying to deploy this to a test machine but when the Web viewer should be displayed I get  System.NullReferenceException: Object reference not set to an instance of an object. full error below.

Googling this it seems that the cause is probably the lack of a crystal reports viewers virtual directory.
Most of the solutions are for earlier versions and I have tried them but it hasn't solved my probelm.

Can anyone help?

Crystal XI R2
ASP.net developed using Visual Studio 2008

TIA

Source Error: 
 
 
Line 22:       width: 487px; height: 118px;" Visible="False"></asp:Label>
Line 23: 
Line 24:       <cr:crystalreportviewer ID="CRV1" runat="server" AutoDataBind="true" BorderStyle="Solid" BorderWidth="1px " 
Line 25:         EnableDrillDown="False" Style="position: absolute;
Line 26:         top: 281px; left: 112px; "/>
 
 
Source File: c:\DMIWeb_proto\InvRep.aspx    Line: 24 
 
Stack Trace: 
 
 
[NullReferenceException: Object reference not set to an instance of an object.]
   CrystalDecisions.Web.CrystalReportViewer.set_EnableDrillDown(Boolean value) +25
   ASP.invrep_aspx.__BuildControlCRV1() in c:\DMIWeb_proto\InvRep.aspx:24
   ASP.invrep_aspx.__BuildControlPanel1() in c:\DMIWeb_proto\InvRep.aspx:19
   ASP.invrep_aspx.__BuildControlContent3(Control __ctrl) in c:\DMIWeb_proto\InvRep.aspx:17
   System.Web.UI.CompiledTemplateBuilder.InstantiateIn(Control container) +12
   ASP.site1_master.__BuildControlContentPlaceHolder2() in c:\DMIWeb_proto\Site1.Master:72
   ASP.site1_master.__BuildControlform1() in c:\DMIWeb_proto\Site1.Master:14
   ASP.site1_master.__BuildControlTree(site1_master __ctrl) in c:\DMIWeb_proto\Site1.Master:1
   ASP.site1_master.FrameworkInitialize() in c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\dmiweb\bb21d111\9a837ecf\App_Web_k--dh2rp.0.cs:0
   System.Web.UI.UserControl.InitializeAsUserControlInternal() +35
   System.Web.UI.MasterPage.CreateMaster(TemplateControl owner, HttpContext context, VirtualPath masterPageFile, IDictionary contentTemplateCollection) +8668175
   System.Web.UI.Page.get_Master() +51
   System.Web.UI.Page.ApplyMasterPage() +15
   System.Web.UI.Page.PerformPreInit() +45
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +282

Open in new window

0
Comment
Question by:Philip Pinnell
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 101

Assisted Solution

by:mlmcc
mlmcc earned 100 total points
ID: 24394817
What service pack do you have installed?

Even with SP5 this article doesn't include VS2008 as a supported platform for development.
https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/907e6412-a7ac-2b10-23a8-f837fcc78a37

mlmcc
0
 
LVL 13

Author Comment

by:Philip Pinnell
ID: 24395076
SP4

Interesting

As I say it works under the deveolpment environment.

So the dlls that provide the web cr viewer are not compatible with vs 2008? or .Net 3.5, I suppose.

Can I not produce an asp.net 2.0 web app from vs 2008 that will be compatible with CR XI R2?

This is confusing because the dev environment seem to be ok.
0
 
LVL 13

Author Comment

by:Philip Pinnell
ID: 24395287
Still not sure what I should have for an ASP.NET v2.0 app and CRXI R2 viewers
0
 
LVL 101

Expert Comment

by:mlmcc
ID: 24395998
I don't know.  I only know what I can read about.  I know some of what I have read, CR XI seems to be an orphaned product.  They are keeping it around for compatibility with the COM world.

The version of Crystal that comes with VS2008 is still based on CR10.  They have had plenty of time to update it to CR XI if they wanted to.

mlmcc
0
 
LVL 13

Accepted Solution

by:
Philip Pinnell earned 0 total points
ID: 24410122
Well I changed target to .Net 2 an this didn't work by itself so don't know if needed. I also created a web setup and included the crystal merge modules.

Everything is working fine.
0

Featured Post

Get MySQL database support online, now!

At Percona’s web store you can order your MySQL database support needs in minutes. No hassles, no fuss, just pick and click. Pay online with a credit card.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you don't have the right permissions set for your WordPress location in IIS, you won't be able to perform automatic updates. Here's how to fix the problem.
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…

635 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