public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport() { crGroundPostDiagram rpt = new crGroundPostDiagram(); rpt.Site = this.Site; return(rpt); }
private void crViewDiagramReport_Load(object sender, EventArgs e) { crGroundPostDiagram Diagram = new crGroundPostDiagram(); DataTable DPack = Atend.Base.Design.DPackage.AccessSelectByType(Convert.ToInt16(Atend.Control.Enum.ProductType.GroundPost)); foreach (DataRow PackRow in DPack.Rows) { Atend.Base.Equipment.EGroundPost Apost = Atend.Base.Equipment.EGroundPost.AccessSelectByCode(Convert.ToInt32(PackRow["ProductCode"].ToString())); DataRow DR = ds.GroundPostDiagram.NewRow(); DR["Name"] = Apost.Name; DR["Image"] = Apost.Image; DR["Capacity"] = Apost.Capacity; ds.GroundPostDiagram.Rows.Add(DR); } Diagram.SetDataSource(ds); crViewDiagramReport.ReportSource = Diagram; }