public void TestExcelDataSourcePanelBeforeRender(DataSourcePanelBeforeRenderEventArgs args)
        {
            IList <TestItem> data = ((IEnumerable <TestItem>)args.Data).ToList();

            data[2].Name = "ChangedName";
            args.Range.LastCell().Delete(XLShiftDeletedCells.ShiftCellsLeft);
        }
 public void TestExcelDynamicPaneBeforeRender(DataSourcePanelBeforeRenderEventArgs args)
 {
     args.Range.Cells().ElementAt(0).Value = "CanceledHeaders";
     args.Range.Cells().ElementAt(1).Value = "CanceledData";
     args.Range.Cells().ElementAt(2).Value = "CanceledTotals";
     args.IsCanceled = true;
 }
        public void TestExcelDynamicPanelBeforeDataRender(DataSourcePanelBeforeRenderEventArgs args)
        {
            var       dataSet   = (DataSet)args.Data;
            DataTable dataTable = dataSet.Tables[0];

            dataTable.Rows[2]["Type"] = 1;
            dataTable.Columns.Add(new DataColumn("DynamicAdded", typeof(decimal)));
            for (int i = 0; i < dataTable.Rows.Count; i++)
            {
                dataTable.Rows[i]["DynamicAdded"] = (i + 1) * 2.6;
            }
        }
 public void TestExcelDynamicPanelBeforeTotalsRender(DataSourcePanelBeforeRenderEventArgs args)
 {
     args.Range.Cells().ElementAt(1).Value = "{Count(di:Name)}";
 }
 public void TestExcelDynamicPanelBeforeTotalsTemplatesRender(DataSourcePanelBeforeRenderEventArgs args)
 {
     args.Range.Style.Font.Italic = true;
 }
 public void TestExcelDynamicPanelBeforeDataTemplatesRender(DataSourcePanelBeforeRenderEventArgs args)
 {
     args.Range.Style.Font.Underline = XLFontUnderlineValues.Single;
 }
        public void TestExcelTotalsPanelBeforeRender(DataSourcePanelBeforeRenderEventArgs args)
        {
            IList <TestItem> data = ((IEnumerable <TestItem>)args.Data).ToList();

            data[0].Sum = 55.78m;
        }