2014-05-16 3 views
0

렌더링 : 그것은 단지 Black and White이 보고서를 내보낼 수있는 방법이 내가 PDF에서의 ReportViewer에서 내 보고서를 내보낼 방법입니다 블랙의 ReportViewer에서 LocalReport 화이트 PDF

Warning[] warnings; 
string[] streamids; 
string mimeType; 
string encoding; 
string extension; 
byte[] myBytes; 
string reportName = hfReportName.Value; 

myBytes = rvReport.LocalReport.Render("PDF", null, out mimeType, out encoding, out extension, out streamids, out warnings); 

Response.Buffer = true; 
Response.Clear(); 
Response.ContentType = mimeType; 
Response.AddHeader("content-disposition", "attachment; filename=" + reportName + "_" + ddlPracGroup.SelectedItem + "." + extension); 
Response.BinaryWrite(myBytes); 
Response.Flush(); 

인가?

답변

0

누군가이 질문을 할 경우를 대비하여 해결책을 게시 할 것입니다.

rdlc 보고서 IsPrintType에 매개 변수를 하나 더 추가합니다. 이것은 불리언 매개 변수입니다. SSRS에서는 보고서를 흑백으로 만 설정할 수 있습니다. 인쇄 버튼을 클릭하면 reload report with this parameter > print report using code above > reload report back with color

코드 샘플이 필요하면 알려주세요.