Access to report file denied.

A Deployed ASP.Net 2.0 website with Crystal Reports viewer (Visual Studio 2005) causes the error below. Apparently, during its load process in creates a copy in the temp directory, but can't read the file in just created. Can I redirect where these files to be created in a specified directory so I can isolate the permissions needed to read the report. Does one of the IIS services need permissions?

Error in File C:\WINDOWS\TEMP\EmployeeFull {4D249D66-7F13-401C-BFF2-9BC7E04934EF}.rpt:
Access to report file denied. Another program may be using it.

Description:An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details:System.Runtime.InteropServices.COMException: Error in File C:\WINDOWS\TEMP\EmployeeFull {4D249D66-7F13-401C-BFF2-9BC7E04934EF}.rpt:
Access to report file denied. Another program may be using it.

[1182 byte] By [DougHuff] at [2007-12-24]
# 1
Doug Huff wrote:

A Deployed ASP.Net 2.0 website with Crystal Reports viewer (Visual Studio 2005) causes the error below. Apparently, during its load process in creates a copy in the temp directory, but can't read the file in just created. Can I redirect where these files to be created in a specified directory so I can isolate the permissions needed to read the report. Does one of the IIS services need permissions?

Error in File C:\WINDOWS\TEMP\EmployeeFull {4D249D66-7F13-401C-BFF2-9BC7E04934EF}.rpt:
Access to report file denied. Another program may be using it.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Runtime.InteropServices.COMException: Error in File C:\WINDOWS\TEMP\EmployeeFull {4D249D66-7F13-401C-BFF2-9BC7E04934EF}.rpt:
Access to report file denied. Another program may be using it.

rmmd at 2007-10-8 > top of Msdn Tech,Visual Studio,Crystal Reports for Visual Studio...
# 2
I have exactly the same error - so what's the fix?
Jackgillespie at 2007-10-8 > top of Msdn Tech,Visual Studio,Crystal Reports for Visual Studio...
# 3
From your setup, Crystal will always create the their temp files in your C:\Windows\Temp directory. In iis 5 the aspnet_wp needs access to this folder. In iis 6 it is the IIS_WPG account that needs access to this folder. I believe it needs, read, write and modify permissions, shouldn't need execute. There is no way to tell it to use another temp directory.
mewdied at 2007-10-8 > top of Msdn Tech,Visual Studio,Crystal Reports for Visual Studio...
# 4

In IIS 6, we gave Network Service Read and Write permissions to the system temp directory. This fixed the permissions problem for us. This is similiar to a problem using Access as your data store.

DougHuff at 2007-10-8 > top of Msdn Tech,Visual Studio,Crystal Reports for Visual Studio...
# 5

This was amazing. I made the changes to IIS, added impersonate to my web.config and a few lines of code to my application and poof it worked. I have been working with Business Objects for over a month on this problem and is gets fixed in just a few minutes.

Thanks

Brad West

BradWest at 2007-10-8 > top of Msdn Tech,Visual Studio,Crystal Reports for Visual Studio...
# 6

I have a some problem.

Would you please give me some steps. How you do this.

Thanks in advance.

Ted Lee

TedLee at 2007-10-8 > top of Msdn Tech,Visual Studio,Crystal Reports for Visual Studio...
# 7
So which is it? The Network Service account or the IIS_WPG account? Or does one use the other for access via IIS6 under Win2K3? Thanx, for the help. It was only two days wasted before I got off the BusinessObjects "support" site and searched the Internet.
eKnave at 2007-10-8 > top of Msdn Tech,Visual Studio,Crystal Reports for Visual Studio...
# 8
You can use either. Network Service is a user who belongs to the IIS_WPG group, so you can set it at the group level, or the individual user.
mewdied at 2007-10-8 > top of Msdn Tech,Visual Studio,Crystal Reports for Visual Studio...

Visual Studio

Site Classified