protected void ButtonExcel_Click(object sender, EventArgs e) { string alternateText = (sender as ImageButton).AlternateText; RadPivotGrid1.ExportSettings.Excel.Format = (PivotGridExcelFormat)Enum.Parse(typeof(PivotGridExcelFormat), alternateText); RadPivotGrid1.ExportSettings.IgnorePaging = CheckBox1.Checked; RadPivotGrid1.ExportToExcel(); }
protected void btnExport_Click(object sender, EventArgs e) { if (dtStart.SelectedDate == null || dtEnd.SelectedDate == null) { return; } string dateformat = "MMMdd"; RadPivotGrid1.ExportSettings.IgnorePaging = true; RadPivotGrid1.ExportSettings.FileName = "Press_" + ((DateTime)dtStart.SelectedDate).ToString(dateformat) + "_to_" + ((DateTime)dtEnd.SelectedDate).ToString(dateformat); RadPivotGrid1.ExportToExcel(); }
protected void btnExport_Click(object sender, EventArgs e) { try { RadPivotGrid1.ExportSettings.Excel.Format = (PivotGridExcelFormat)Enum.Parse(typeof(PivotGridExcelFormat), "Xlsx"); RadPivotGrid1.ExportSettings.IgnorePaging = true; RadPivotGrid1.ExportSettings.OpenInNewWindow = true; RadPivotGrid1.ExportSettings.FileName = "Summary"; RadPivotGrid1.ExportToExcel(); } catch (Exception ex) { RadWindowManager1.RadAlert(ex.Source + " - " + ex.Message, 400, 200, "Error!", null, ""); } }
protected void RadPushButton2_Click(object sender, EventArgs e) { RadPivotGrid1.ExportToExcel(); }
protected void btn_ConvertToExcel_Click(object sender, ImageClickEventArgs e) { RadPivotGrid1.ExportSettings.FileName = "Report"; RadPivotGrid1.ExportToExcel(); }