小编Wil*_*ill的帖子

报告查看器错误消息"客户端找到响应内容类型''但预期'文本xml'请求失败并显示空响应."

我收到了错误

client found response content type of '' but expected 'text xml' The request failed with an empty response.
Run Code Online (Sandbox Code Playgroud)

当我尝试执行以下代码时.

//create a PDF from the SQL report
ReportViewer rview = new ReportViewer();

rview.ServerReport.ReportServerUrl = new Uri("http://server/ReportServer$MSSQL2K5?");

List<ReportParameter> paramList = new List<ReportParameter>();
paramList.Add(new Microsoft.Reporting.WinForms.ReportParameter("Batch", "1"));
paramList.Add(new Microsoft.Reporting.WinForms.ReportParameter("InvoiceNo", "0"));
rview.ServerReport.ReportPath = "Report/Report Invoice";

rview.ServerReport.SetParameters(paramList);

string mimeType, encoding, extension, deviceInfo;
string[] streamids;
Microsoft.Reporting.WinForms.Warning[] warnings;
string format = "PDF"; //Desired format goes here (PDF, Excel, or Image)             

deviceInfo =
"<DeviceInfo>" +
"<SimplePageHeaders>True</SimplePageHeaders>" +
"</DeviceInfo>"; …
Run Code Online (Sandbox Code Playgroud)

c# reporting-services

8
推荐指数
2
解决办法
2万
查看次数

标签 统计

c# ×1

reporting-services ×1