private void OnSectionPrinted(object sender, SectionRenderEventArgs e) { if (this.SectionRendered != null) { this.SectionRendered(this, e); } }
private void OnSectionPrinted(object sender, SectionEventArgs e) { if (this.SectionRendered != null) { SectionRenderEventArgs ea = new SectionRenderEventArgs(e.Section, this.currentPageNumber, this.CurrentRow, this.CurrentSection); this.SectionRendered(this, ea); } }
private void OnSectionPrinted (object sender,SectionRenderEventArgs e) { if (this.SectionRendered != null) { this.SectionRendered (this,e); } }
private void PushPrinting (object sender, SectionRenderEventArgs e ) { string sectionName = e.Section.Name; /* if (sectionName == ReportSectionNames.ReportHeader) { Console.WriteLine("PushPrinting :" + ReportSectionNames.ReportHeader); } else if (sectionName == ReportSectionNames.ReportPageHeader) { Console.WriteLine("PushPrinting :" +ReportSectionNames .ReportPageHeader); } else if (sectionName == ReportSectionNames.ReportDetail){ Console.WriteLine("PushPrinting :" + ReportSectionNames.ReportDetail); // TimeWritten BaseDataItem time = e.Section.FindItem("BaseDataItem1") as BaseDataItem; if (time != null) { DateTime dateTime = Convert.ToDateTime(time.DBValue); int newhour = dateTime.Hour; if (hour != newhour) { hour = newhour; e.Section.Items[0].DrawBorder = true; e.Section.Items[0].FrameColor = Color.Black; // e.Section.Items[0].BackColor = Color.LightGray; time.DBValue = dateTime.Hour.ToString(); time.ContentAlignment = ContentAlignment.MiddleLeft; } else { time.DrawBorder = false; e.Section.Items[0].FrameColor = Color.White; // e.Section.Items[0].BackColor = Color.White; time.DBValue = dateTime.Minute.ToString() + ":" + dateTime.Second.ToString(); time.ContentAlignment = ContentAlignment.MiddleRight; } } // D:\SharpDevelop3.0_WorkingCopy\SharpDevelop\samples\SharpDevelopReports\SampleReports\EventLogger\Error.png // Image BaseDataItem dataItem = e.Section.FindItem("EntryType") as BaseDataItem; if (dataItem != null) { string str = dataItem.DBValue; Image image = null; if (str == "Information") { image = this.imageList.Images[1]; } else if (str == "Warning") { image = this.imageList.Images[2]; } else if (str == "Error") { image = this.imageList.Images[0]; } if (image != null) { BaseImageItem imageItem = e.Section.FindItem("BaseImageItem1") as BaseImageItem; if (imageItem != null) { imageItem.Image = image; } } } } else if (sectionName == ReportSectionNames.ReportPageFooter){ Console.WriteLine("PushPrinting :" + ReportSectionNames.ReportPageFooter); } else if (sectionName == ReportSectionNames.ReportFooter){ Console.WriteLine("PushPrinting :" + ReportSectionNames.ReportFooter); } else{ throw new WrongSectionException(sectionName); } */ }
private void OnSectionPrinted (object sender,SectionEventArgs e) { if (this.SectionRendered != null) { SectionRenderEventArgs ea = new SectionRenderEventArgs (e.Section, this.currentPageNumber, this.CurrentRow, this.CurrentSection); this.SectionRendered(this,ea); } }