G
Guest
I created a page in Visual Studio 2005 with a Crystal Reports web viewer
attached to a report. The report previews fine, but clicking the embedded
Print button produces an error:
"HTTP 403.1 Forbidden: Execute Access Forbidden
Internet Information Services"
"You have attempted to execute a CGI, ISAPI, or other executable program
from a directory that does not allow programs to be executed."
Impersonation is set to true in the web.config with a machine userid and
password for the web server. Seems like Crystal needs to be able to write to
a temp directory on the server and users don't have access to this with their
Windows domain accounts.
The Page Load event for the page with the viewer looks like:
crReportDocument.Load(Server.MapPath("Summary.rpt"));
crConnectionInfo.ServerName = "MyServer";
crConnectionInfo.DatabaseName = "DatabaseName";
crConnectionInfo.UserID = "****";
crConnectionInfo.Password = "****";
crDatabase = crReportDocument.Database;
crTables = crDatabase.Tables;
//Loop through all tables in the report and apply the
//connection information for each table.
for (int i = 0; i < crTables.Count; i++)
{
crTable = crTables ;
crTableLogOnInfo = crTable.LogOnInfo;
crTableLogOnInfo.ConnectionInfo = crConnectionInfo;
crTable.ApplyLogOnInfo(crTableLogOnInfo);
CrystalReportViewer1.ReportSource = crReportDocument;
If anyone could shed light on this problem for me I would be very grateful.
All necessary permissions have been applied to the virtual directory in IIS.
Thanks,
Steve
attached to a report. The report previews fine, but clicking the embedded
Print button produces an error:
"HTTP 403.1 Forbidden: Execute Access Forbidden
Internet Information Services"
"You have attempted to execute a CGI, ISAPI, or other executable program
from a directory that does not allow programs to be executed."
Impersonation is set to true in the web.config with a machine userid and
password for the web server. Seems like Crystal needs to be able to write to
a temp directory on the server and users don't have access to this with their
Windows domain accounts.
The Page Load event for the page with the viewer looks like:
crReportDocument.Load(Server.MapPath("Summary.rpt"));
crConnectionInfo.ServerName = "MyServer";
crConnectionInfo.DatabaseName = "DatabaseName";
crConnectionInfo.UserID = "****";
crConnectionInfo.Password = "****";
crDatabase = crReportDocument.Database;
crTables = crDatabase.Tables;
//Loop through all tables in the report and apply the
//connection information for each table.
for (int i = 0; i < crTables.Count; i++)
{
crTable = crTables ;
crTableLogOnInfo = crTable.LogOnInfo;
crTableLogOnInfo.ConnectionInfo = crConnectionInfo;
crTable.ApplyLogOnInfo(crTableLogOnInfo);
CrystalReportViewer1.ReportSource = crReportDocument;
If anyone could shed light on this problem for me I would be very grateful.
All necessary permissions have been applied to the virtual directory in IIS.
Thanks,
Steve