locked
Crystal Report Error - VS2010 RRS feed

  • Question

  • User-1267019744 posted

    Hi guys,

    The problem is in the crv.js, at  

    Sys.Application.notifyScriptLoaded();

    when I try to open a report is shows  Microsoft JScript runtime error: 'Sys.Application' is null or not an object

    If I click Ignore or Continue, it's show the report properly, but when I deploy it to the development server it does not work.

     

    At this time I am trying to open a simple report with the date and page number.

    there is a CrystalReportViewer at the Default.aspx page.

     

    the code is

     

    Public Class _Default
        Inherits System.Web.UI.Page
    
        Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
    
            If Not IsPostBack Then
    
                Me.CrystalReportViewer1.ReportSource = New Report_Test
    
            End If
    
        End Sub
    
    End Class

     

    Thanks

    Thursday, August 5, 2010 5:07 AM

Answers

  • User-1267019744 posted

    to fixed that i've changed in the original file

     

    if(typeof(Sys)!=='undefined') {
        Sys.Application.notifyScriptLoaded();
    }

     

    for

     

    if(typeof(Sys.Application)!=='undefined') {
        Sys.Application.notifyScriptLoaded();

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Friday, August 6, 2010 2:27 AM

All replies

  • User-1267019744 posted

    to fixed that i've changed in the original file

     

    if(typeof(Sys)!=='undefined') {
        Sys.Application.notifyScriptLoaded();
    }

     

    for

     

    if(typeof(Sys.Application)!=='undefined') {
        Sys.Application.notifyScriptLoaded();

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Friday, August 6, 2010 2:27 AM
  • User961323001 posted

    I have the same problem when using a crystal report viewer in vs2010. I have tried to modify the crv.js files as you did but when I run the application I get the same error as before. Looking at the script in VS at run time it looks like it is not picking up the changes I made. The files I have tried to modify are the following:

    C:\inetpub\wwwroot\aspnet_client\system_web\2_0_50727\crystalreportviewers14\js\crviewer\crv.js

    C:\Program Files\SAP BusinessObjects\Crystal Reports 14.0\crystalreportviewers\js\crviewer\crv.js

    C:\inetpub\wwwroot\aspnet_client\system_web\2_0_50727\crystalreportviewers12\js\crviewer\crv.js

    C:\inetpub\wwwroot\aspnet_client\system_web\4_0_30319\crystalreportviewers14\js\crviewer\crv.js

    I am launching the application from within visual studio. What was the location of the file you edited?

     

     

     

     

    Saturday, August 7, 2010 6:06 PM
  • User-1267019744 posted

    Hi RyanDansie,

    I edited all of them,  but the one that made effect was

    C:\Program Files\SAP BusinessObjects\Crystal Reports 14.0\crystalreportviewers\js\crviewer\crv.js

    Edit all of those, close all aplications, open the files in notepad, change them and save ... that's how I did, It's working properly now.

    Sunday, August 8, 2010 8:42 PM
  • User190128990 posted

    I tried all possible solutions which appeared on the net for the Microsoft runtime JS errors encountered during execution of Crystal Reports. But None of them worked. Finally I hit upon the idea of trying a full postback on Submit Button for viewing the report. It just did wonders. All reports there on worked beautifully with data getting refreshed with new data on each submit as per report parameter values submitted.

    If you are using AJAX, attach Full PostBack trigger to the Submit Button.

    Thursday, December 1, 2011 1:45 PM