简体   繁体   中英

LocalReport fails to render while calling through Process.Start

I have to use quite old program that was written in .net framework in my asp.net core application.

This program is a simple console application that uses Microsoft.ReportViewer to generate pdf. I'm using Process.Start to execute the exe file. It works perfectly on my local machine, however, when I deploy it to the IIS, it throws following error:

An error occurred during local report processing.

The definition of the report '' is invalid.

It is strange, because when I execute the exe file manually (while logged in through the Remote Desktop) it works without any problems.

Failing line looks like this: renderedBytes = report.Render(reportType, deviceInfo);

I've tried some solutions that were posted in the past, but none of them seems to work.

Have you ever encountered similar problem?

Check that IIS account has the correct permissions to execute the exe. The account should be NETWORK SERVICES. Check the permission on the fold where the exe is located as well.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM