私のasp.net mvc3(Razor)アプリケーションではrdlc、レポートに使用しています。印刷目的のために私はちょうどneed to convert the rdlc into image。次のコードを試しました
   public ActionResult FilePrint()
    {
        LocalReport localReport = new LocalReport();
        localReport.ReportPath = @"Reports/OP/Rdlc/ClinicInvoiceReceipt.rdlc";
        iClinicInvoiceReceipt = new RmtOPInvoice.ClinicInvoiceReceipt();
        DataTable dt = iClinicInvoiceReceipt.SelectReceiptDtlForPrint(2);
        ReportDataSource reportDataSource = new ReportDataSource();
        reportDataSource.Value = dt;
        reportDataSource.Name = "DataSet1";
        localReport.DataSources.Add(reportDataSource);
        string reportType = "Image";
        string mimeType;
        string encoding;
        string fileNameExtension;
        Warning[] warnings;
        string[] streams;
        byte[] renderedBytes;
        //Render the report
        renderedBytes = localReport.Render(
            reportType,
            null,
            out mimeType,
            out encoding,
            out fileNameExtension,
            out streams,
            out warnings);
        return File(renderedBytes, "Image");
  }
とビューで
 <img src="@Url.Action("FilePrint","ClinicInvoiceReceipt")" />
しかし、それは機能しません。どうすればこれを達成できますか?誰か知っているなら共有してください。