我试图将水晶报告导出为 pdf 格式。但我出现错误,例如“System.IO.MemoryStream”是“类型”,但用作“变量”......这是我的代码,请验证并纠正我..
protected void Button1_Click(object sender, EventArgs e)
{
MemoryStream MS;
MS = (MemoryStream);
MR.ExportToStream(CrystalDecisions.Shared.ExportFormatType.PortableDocFormat);
Response.Clear();
Response.Buffer = true;
Response.ContentType = "application/pdf";
Response.BinaryWrite(MS.ToArray());
Response.End();
}