If you became a customer of the Syncfusion� Reporting Platform or the Report Viewer, Report Designer, or Report Writer components before October 2019 and have questions related to those products, you can request support through our forum system. However, please note that this support system is only for existing customers who are still using the Syncfusion� Reporting Platform or its components and not for new customers looking for reporting products from Syncfusion�.

For new customers or those with general reporting questions, we recommend contacting our support team at https://support.boldreports.com/, which is a separate brand created by Syncfusion� for its reporting solutions. Our team will be happy to assist you with any questions you may have.

Thank you for choosing Syncfusion� for your reporting needs.

Report Viewer cannot read property toLowerCase

Hi there,

I have a Report Viewer implementation on server-side that is unable to render a report on Angular client. When I create an standlone project with an easy implementation, it works correctly so the report renders, but when I try to copy the same base code into my API Net Framework project, it throws the following error on the client side:

ERROR TypeError: Cannot read property 'toLowerCase' of undefined
    at Object._updateExportSetup (bold.report-viewer.min.js:10)
    at Object._renderCurrentPageModels (bold.report-viewer.min.js:10)
    at Object._getPageImages (bold.report-viewer.min.js:10)
    at Object.success (bold.report-viewer.min.js:10)
    at fire (jquery.js:3268)
    at Object.fireWith [as resolveWith] (jquery.js:3398)
    at done (jquery.js:9305)
    at XMLHttpRequest. (jquery.js:9548)
    at XMLHttpRequest.wrapFn (zone.js:1281)
    at ZoneDelegate.push../node_modules/zone.js/dist/zone.js.ZoneDelegate.invokeTask (zone.js:423)

Someone can help with this? Just let me know if some additional details are necessary on my side.

Thank you very much.

Kind regards,


5 Replies 1 reply marked as answer

MR Manoranjan Rajendran Syncfusion Team May 20, 2021 11:04 AM UTC

Hi Israel, 
 
We have validated the reported issue from our end. We were not able to reproduce the reported issue. Could you please ensure same version of Bold reports scripts and nuget are used in your client and server side sample. We have prepared the sample application could you please check this and share the issue reproducible sample to us. Its helpful for our further validation.  
 
 
Regards, 
Manoranjan R 


Marked as answer

TH Tim Ho June 6, 2021 01:33 AM UTC

I'm also getting this below error:

ERROR TypeError: Cannot read property 'toLowerCase' of undefined
    at Object._updateExportSetup (vendor.js:182287)
    at Object._renderCurrentPageModels (vendor.js:182287)
    at Object._getPageModel (vendor.js:182287)
    at Object.success (vendor.js:182287)
    at fire (scripts.js:22868)
    at Object.fireWith [as resolveWith] (scripts.js:22998)
    at done (scripts.js:29158)
    at XMLHttpRequest. (scripts.js:29419)
    at XMLHttpRequest.nrWrapper (report:23)
    at XMLHttpRequest.wrapFn (polyfills.js:17454)

I ensured the version are the same on both ensure the same version on both Angular and API sides.   I tried bold reports version 2.2.28, v3.1.34 same error.  I did follow everything you do in your example as well.  I'm not sure what to do from here.  The viewer shows nothing




MR Manoranjan Rajendran Syncfusion Team June 7, 2021 09:19 AM UTC

Hi Tim,   
  
Thanks for contacting Bold Reports support.   
  
Please share your Angular version details and confirm whether our shared sample is working fine at your end. If possible, please share a simple issue reproducible sample to us. It will be helpful for our further validation.   
  
Regards,   
Manoranjan R   



JU Juvenalis July 29, 2021 10:38 AM UTC

Hi  Manoranjan ,

I too get the same error when I  set   ContractResolver to  CamelCasePropertyNamesContractResolver as shown on code below


 public class Startup

    {

        public void Configuration(IAppBuilder app)

        {



            var config = GlobalConfiguration.Configuration;

            config.Formatters.JsonFormatter.UseDataContractJsonSerializer = false;

            config.Formatters.JsonFormatter.SerializerSettings = new Newtonsoft.Json.JsonSerializerSettings

            {

                DateFormatHandling = Newtonsoft.Json.DateFormatHandling.IsoDateFormat,

                DateTimeZoneHandling = Newtonsoft.Json.DateTimeZoneHandling.Local,

                ContractResolver = new Newtonsoft.Json.Serialization.CamelCasePropertyNamesContractResolver(),

            };

        }

    }




MR Manoranjan Rajendran Syncfusion Team July 30, 2021 06:32 AM UTC

Hi Juvenalis, 
 
Thanks for contacting Bold reports support, 
 
If you are using the camel serializer for your application, then will have a problem in processing API result with Report Viewer. So, you have to use the default resolver for using the Report Viewer.  We suggest you to follow the below documentation for this issue.  
 
Regards,  
Manoranjan R  


Loader.
Up arrow icon