我正在尝试添加外部照片作为徽标以及report.rdlc
文件上的报告。我有这个错误
尚未为此报告设置启用 externalimages 属性
?
这是我的代码。
try
{
this.pedidosTableAdapter.Connection.ConnectionString = con.MysqlConnect();
this.pedidosTableAdapter.Fill(this.fabricacaoDataSet8.pedidos, Pages.relatorios.num);
this.reportViewer1.RefreshReport();
}
catch { }
// for external image
this.reportViewer1.LocalReport.EnableExternalImages = true;
ReportParameter parm = new ReportParameter();
parm=(new ReportParameter("path", @"C:\logo.jpg",true));
this.reportViewer1.LocalReport.SetParameters(parm);
this.reportViewer1.Refresh();