Creating reports and dashboards | Stimulsoft community forum
Reporting tool and data analytics tools for creating reports and dashboards in ASP.NET, ASP.NET MVC, .NET Core, Blazor, Angular, PHP, Python, WPF, JavaScript, and Java applications.
stiReport1.Load(rootPath + "\\report.mrt");
//Connecting SQL Server data source
stiReport1.Dictionary.Databases.Clear();
stiReport1.Dictionary.Databases.Add(new StiSqlDatabase("SQLConnection", cstr));
Stimulsoft.Report.Export.StiPdfExportSettings pdf = new Stimulsoft.Report.Export.StiPdfExportSettings();
pdf.Compressed = true;
...
stiReport1.Render();
stiReport1.ExportDocument(StiExportFormat.Pdf, file, pdf);
Works on my local machine with Stimulsoft installed but not on a web-hotel. After a couple of minutes I get "webpage cannot be displayed". I've increased all time-out settings way beyond that. I've also copied all .dll and .exe files from Stimulsoft\Bin\ to my web site\Bin\. What else should I do?
The trust level is set to Medium on the web server. Is it enough? I've tried to change it to Full in the web.config but that was not allowed.
I have write permissions and the aspx page can create other files in that folder.
Please, make sure that your project take the latest assemblies.
Read the How the Runtime Locates Assemblies article http://msdn.microsoft.com/en-us/library ... v=vs.80%29.
As you could read there the common language runtime check for Previously Referenced Assemblies and the Global Assembly Cache.
So you should remove ALL old assembles from your system.
Please, replace assemblies from GAC with latest ones and search all over your system for any other our assemblies.
I've removed all the assemblies from GAC. Deleted all files in Temporary ASP.NET files. Referenced the right version in the web.config. It worked once but than again it started to create empty files. Debugging the code showed that the call:
stiReport1.Render();
...only took a micro-second even if the report has 49 pages, so I guess it's where it all goes wrong. Which assemlies are used during rendering. Should I reference any of the .exe files?
When changing the calculationMode I get "Incorrect syntax near '}'"- error (see attached screenshot). I have a couple of stored procedures with parameters (within brackets {...}) and it seems that in this mode, they are not supplied to the execute-call. When I don't set the CalculationMode it works fine (on my computer)
Also I've replaced my .mrt file with a simple one with only one page and no datasources and it works fine to generate the PDF-file on the web-server so I guess the trust-level and assemblies are ok. I will try to add more advanced charts and datasources and hopefully isolate the one(s) that's causing the problem. Meanwhile all ideas and suggestions are of great value.