하위 보고서의 매개 변수를 프로그래밍 방식으로 설정하는 방법은 무엇입니까? 최상위 보고서를 들어, 다음과 같은 작업을 수행 할 수 있습니다 위의 같은SSRS - ReportViewer LocalReport SubReport 매개 변수 값 설정
reportViewer.LocalReport.SetParameters ( new Microsoft.Reporting.WebForms.ReportParameter[] { new Microsoft.Reporting.WebForms.ReportParameter("ParameterA", "Test"), new Microsoft.Reporting.WebForms.ReportParameter("ParameterB", "1/10/2009 10:30 AM"), new Microsoft.Reporting.WebForms.ReportParameter("ParameterC", "1234") } );
매개 변수 전달은 최상위 보고서가 아닌 하위 보고서에 전달할 것으로 보인다.
LocalReport를 사용하면 SubreportProcessing 이벤트를 처리 할 수 있습니다. 그러면 ReportParameterInfoCollection 유형의 속성을 가진 SubreportProcessingEventArgs의 인스턴스가 전달됩니다. 이 컬렉션의 값은 읽기 전용입니다.
어디서 처리 할 수 있는지 알아낼 수 있습니까? – rsapru
내 대답을 참조하십시오 도움이 될 수 있습니다. http://stackoverflow.com/a/15737703/1148288 –