呼伦贝尔网站建设呼伦贝尔,天津网站建设推荐安徽秒搜科技,钢材原材料东莞网站建设,百度小说风云榜排名FastReport Business Graphics .NET#xff0c;是一款基于fastreport报表开发控件的商业图形库#xff0c;借助 FastReport 商业图形库#xff0c;您可以可视化不同的分层数据#xff0c;构建业务图表以进行进一步分析和决策。利用数据呈现领域专家针对 .NET 7、.NET Core、…FastReport Business Graphics .NET是一款基于fastreport报表开发控件的商业图形库借助 FastReport 商业图形库您可以可视化不同的分层数据构建业务图表以进行进一步分析和决策。利用数据呈现领域专家针对 .NET 7、.NET Core、Blazor、ASP.NET、MVC、Windows Forms 和 Mono 提供的完整的产品
FastReport .NET 是适用于.NET Core 3ASP.NETMVC和Windows窗体的全功能报告库。使用FastReport .NET您可以创建独立于应用程序的.NET报告。 FastReport .net下载qun278631305https://www.evget.com/product/1861/download
新事件 PageCreate 在 FastReport .NET 引擎中创建新页面时发生。在此阶段您可以更改页面的属性。 StartPage、FinishPage 和 ManualBuild 等其他事件在构建页面模板开始/结束之前触发。
例如您可以在横向和纵向页面方向之间交替。或者借助此事件您可以创建一个单独的数据源其中包含有关 ExportAlias 或其他页面属性的信息。在事件执行过程中您可以设置参数并在下一页的开头迭代数据源。
以下示例描述了使用 PageCreate 事件定义 ExportAlias 的修改后的演示报告。 ?xml version1.0 encodingutf-8?
Report ScriptLanguageCSharp TextQualityRegular ReportInfo.DescriptionDemonstrates a group report. To create it:#13;#10;- go to Report|Configure Bands... menu;#13;#10;- press Add button and add a group header (this will add a data band and a group footer as well);#13;#10;- return to the report page, doubleclick the group header to show its editor. ReportInfo.Created01/17/2008 04:31:41 ReportInfo.Modified03/13/2024 17:32:59 ReportInfo.CreatorVersion1.0.0.0
ScriptText
using System;
using System.Collections;
using System.Collections.Generic;
using System.ComponentModel;
using System.Windows.Forms;
using System.Drawing;
using System.Data;
using FastReport;
using FastReport.Data;
using FastReport.Dialog;
using FastReport.Barcode;
using FastReport.Table;
using FastReport.Utils;namespace FastReport
{
public class ReportScript
{
private void Page1_CreatePage(object sender, EventArgs e)
{
if(Data1.DataSource.RowCount 0)
Data1.InitDataSource();
Page1.ExportAlias Data1.DataSource[ProductName].ToString().Substring(0,1);
}
}
}
/ScriptText
Styles
Style NameEvenRows Fill.ColorOldLace FontArial, 10pt/
/Styles
Dictionary
TableDataSource NameProducts ReferenceNameNorthWind.Products DataTypeSystem.Int32 Enabledtrue
Column NameProductID DataTypeSystem.Int32/
Column NameProductName DataTypeSystem.String/
Column NameSupplierID DataTypeSystem.Int32/
Column NameCategoryID DataTypeSystem.Int32/
Column NameQuantityPerUnit DataTypeSystem.String/
Column NameUnitPrice DataTypeSystem.Decimal/
Column NameUnitsInStock DataTypeSystem.Int16/
Column NameUnitsOnOrder DataTypeSystem.Int16/
Column NameReorderLevel DataTypeSystem.Int16/
Column NameDiscontinued DataTypeSystem.Boolean BindableControlCheckBox/
Column NameEAN13 DataTypeSystem.String/
/TableDataSource
Total NameTotalProducts TotalTypeCount EvaluatorData1 PrintOnGroupFooter1/
/Dictionary
ReportPage NamePage1 Watermark.FontArial, 60pt CreatePageEventPage1_CreatePage
ReportTitleBand NameReportTitle1 Width718.2 Height103.95 CanGrowtrue
TextObject NameText1 Top56.7 Width718.2 Height47.25 TextALPHABETICAL PRODUCT LIST HorzAlignCenter VertAlignCenter FontTahoma, 14pt, styleBold/
TextObject NameText11 Top28.35 Width718.2 Height28.35 AnchorTop, Left, Right Fill.ColorWhiteSmoke CanGrowtrue CanShrinktrue Text[Report.ReportInfo.Description]#13;#10; Padding4, 4, 4, 4 FontTahoma, 8pt/
TextObject NameText18 Width718.2 Height28.35 AnchorTop, Left, Right Fill.ColorWhiteSmoke CursorHand Hyperlink.Valuehttp://fast.report/cda2a Hyperlink.OpenLinkInNewTabtrue TextLearn how to build this report on the Fast Reports Academy channel VertAlignCenter FontTahoma, 10pt, styleBold, Underline TextFill.ColorBlue/
/ReportTitleBand
GroupHeaderBand NameGroupHeader1 Top107.15 Width718.2 Height37.8 StartNewPagetrue KeepWithDatatrue Condition[Products.ProductName].Substring(0,1) SortOrderNone
TextObject NameText7 Left9.45 Width699.3 Height37.8 Border.LinesAll Border.ColorLightSkyBlue FillLinearGradient Fill.StartColorLightSkyBlue Fill.EndColorAliceBlue Fill.Angle90 Fill.Focus0.42 Fill.Contrast1 Text[[Products.ProductName].Substring(0,1)] Padding5, 0, 0, 0 VertAlignCenter FontTahoma, 12pt, styleBold/
DataBand NameData1 Top148.15 Width718.2 Height18.9 DataSourceProducts KeepTogethertrue
TextObject NameText2 Left9.45 Width604.8 Height18.9 Border.LinesLeft Border.ColorLightSkyBlue Text[Products.ProductName] VertAlignCenter FontTahoma, 8pt
Highlight
Condition Expression[Row#] % 2 0 Fill.ColorAliceBlue TextFill.ColorBlack FontArial, 10pt ApplyFilltrue ApplyTextFillfalse/
/Highlight
/TextObject
TextObject NameText4 Left614.25 Width94.5 Height18.9 Border.LinesRight Border.ColorLightSkyBlue Text[Products.UnitPrice] FormatCurrency Format.UseLocaletrue Format.DecimalDigits2 HorzAlignRight VertAlignCenter FontTahoma, 8pt
Highlight
Condition Expression[Row#] % 2 0 Fill.ColorAliceBlue TextFill.ColorBlack FontArial, 10pt ApplyFilltrue ApplyTextFillfalse/
/Highlight
/TextObject
Sort
Sort Expression[Products.ProductName]/
/Sort
/DataBand
GroupFooterBand NameGroupFooter1 Top170.25 Width718.2 Height47.25 KeepWithDatatrue
TextObject NameText8 Left9.45 Width699.3 Height18.9 Border.LinesLeft, Right, Bottom Border.ColorLightSkyBlue TextTotal products: [TotalProducts] HorzAlignRight VertAlignCenter FontTahoma, 8pt, styleBold/
/GroupFooterBand
/GroupHeaderBand
PageFooterBand NamePageFooter1 Top220.7 Width718.2 Height28.35 Fill.ColorWhiteSmoke
TextObject NameText9 Left614.25 Width94.5 Height28.35 Text[PageN] HorzAlignRight VertAlignCenter FontTahoma, 8pt/
TextObject NameText12 Left9.45 Width217.35 Height28.35 CursorHand Hyperlink.Valuehttps://www.fast-report.com/en/product/fast-report-net/ TextGenerated by FastReport .NET VertAlignCenter FontTahoma, 8pt, styleUnderline TextFill.ColorBlue/
/PageFooterBand
/ReportPage
/Report将示例中的报表导出到 Excel 2007 的结果 注意 1.调用新事件后Engine.CurPage 会增加并且由于 CurPage 是页面的索引因此在创建前两个页面时其值为 0。因此我们建议在使用新事件时在报告脚本中使用单独的页面计数器。
注意 2.当将 Visible 属性更改为 false 时页面的进一步构建将停止。
借助新属性您可以移动到新的数据记录行并在添加新页面时修改页面属性。