using DevExpress.Export;
using DevExpress.XtraPrinting;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace OlympiaIntranet
{
    public partial class OrdiniFondiUBS : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }

        protected void btnEsportaExcel_Click(object sender, EventArgs e)
        {
            gvOrdiniFondiUBS.Settings.GridLines = System.Web.UI.WebControls.GridLines.None; // Toglie i bordi nelle celle, per visualizzare come in Excel

            ASPxGridViewExporter1.ExportSelectedRowsOnly = false;
            ASPxGridViewExporter1.FileName = DateTime.Now.ToString("yyyyMMdd_HHmm") + " - Ordini_Fondi_UBS";
            XlsxExportOptionsEx op = new XlsxExportOptionsEx() { ExportType = ExportType.DataAware };
            ASPxGridViewExporter1.WriteXlsxToResponse(op);

        }
    }
}