HFSoft.ReportBases

HFSoft.ReportBases.PrintDocument print  =   new  HFSoft.ReportBases.PrintDocument();
        HFSoft.ReportBases.RowItem row;
        HFSoft.ReportBases.CellItem cell;
        row 
=  print.Heard.CreateItem();
        cell 
=  row.Cells.CreateCell( " a " " 业绩ID " );
        cell.Style.BorderStyle 
=  HFSoft.ReportBases.BorderStyle.All;
        cell.Style.BackColor 
=  HFSoft.ReportBases.Color.gray40;
        cell.Style.Height 
=   19.50 ;
        cell.Style.Width 
=   17.63 ;
        cell 
=  row.Cells.CreateCell( " b " " 客户ID " );
        cell.Style.BorderStyle 
=  HFSoft.ReportBases.BorderStyle.All;
        cell.Style.BackColor 
=  HFSoft.ReportBases.Color.gray40;
        cell.Style.Height 
=   19.50 ;
        cell.Style.Width 
=   17.63 ;
        cell 
=  row.Cells.CreateCell( " c " " 积分 " );
        cell.Style.BorderStyle 
=  HFSoft.ReportBases.BorderStyle.All;
        cell.Style.BackColor 
=  HFSoft.ReportBases.Color.gray40;
        cell.Style.Height 
=   19.50 ;
        cell.Style.Width 
=   17.63 ;
        cell 
=  row.Cells.CreateCell( " d " " 时间 " );
        cell.Style.BorderStyle 
=  HFSoft.ReportBases.BorderStyle.All;
        cell.Style.BackColor 
=  HFSoft.ReportBases.Color.gray40;
        cell.Style.Height 
=   19.50 ;
        cell.Style.Width 
=   17.63 ;
        HFSoft.ReportBases.ListTemplate template 
=   new  HFSoft.ReportBases.ListTemplate();
        print.ListTemplate 
=  template;
        row 
=  template.ListItems.CreateItem();
        cell 
=  row.Cells.CreateFieldCell( " a " " PerformanceID " );
        cell.Style.BorderStyle 
=  HFSoft.ReportBases.BorderStyle.All;
        cell 
=  row.Cells.CreateFieldCell( " b " " CustomersID " );
        cell.Style.BorderStyle 
=  HFSoft.ReportBases.BorderStyle.All;
        cell 
=  row.Cells.CreateFieldCell( " c " " point " );
        cell.Style.BorderStyle 
=  HFSoft.ReportBases.BorderStyle.All;
        cell 
=  row.Cells.CreateFieldCell( " d " " date " );

        
        cell.Style.BorderStyle 
=  HFSoft.ReportBases.BorderStyle.All;
        row 
=  print.Footer.CreateItem();
        cell 
=  row.Cells.CreateCell( " a " " 合计 " );
        cell.Style.BorderStyle 
=  HFSoft.ReportBases.BorderStyle.All;
        cell 
=  row.Cells.CreateCell( " b " , "" );
        cell.Style.BorderStyle 
=  HFSoft.ReportBases.BorderStyle.All;
        cell 
=  row.Cells.CreateSum( " c " " point " );

        cell.Style.BorderStyle 
=  HFSoft.ReportBases.BorderStyle.All;
        cell 
=  row.Cells.CreateCell( " d " "" );

       
        cell.Style.BorderStyle 
=  HFSoft.ReportBases.BorderStyle.All;

       
/*DataSet ds1 = new DataSet();
        ds1 = (DataSet)Session["dst"];
*/

        DataSet ds 
=   new  DataSet();
        ds 
=  SqlHelper.ExecuteDataset(ConStr, CommandType.Text,  " select * from Performance  " );
        print.DataSource 
=  ds.Tables[ 0 ].DefaultView;
        Response.Write(HFSoft.ReportWebEngine.WebExcelDocument.Export(print));

你可能感兴趣的:(port)