최종 사용자 디자이너를보고 섹션 기반 보고서 섹션에 컨트롤을 추가하려면 SectionReport 클래스를 사용하여 최종 사용자 디자이너 보고서를 캐스팅하고 그에 따라 섹션에 액세스해야합니다.
다음
private void button1_Click(object sender, EventArgs e)
{
GrapeCity.ActiveReports.SectionReportModel.TextBox txtBox = new GrapeCity.ActiveReports.SectionReportModel.TextBox();
txtBox.Text = "Hello World!";
txtBox.Location = new Point(1, 1);
txtBox.Size = new SizeF(2, 0.5f);
((GrapeCity.ActiveReports.SectionReport)reportdesigner.Report).Sections["Detail"].Controls.Add(txtBox);
}
reportDesigner 디자이너 컨트롤의 이름입니다 예를 들어 버튼 클릭에 보고서의 "세부 정보"섹션에 텍스트 상자를 추가하는 다음 코드를 확인하십시오. 희망이 도움이됩니다.
답변을 주셔서 감사합니다. 답변은 ActiveReports에서 매우 드뭅니다. 나는 문서를 연구함으로써 해결책을 얻었습니다. 내 솔루션도 게시 할 예정입니다. – Ammar
귀하의 답변이 내 해결책보다 타자로 보입니다. – Ammar