コード例 #1
0
ファイル: FrmLayoutLine.cs プロジェクト: github188/myitoppsp
        private void barButtonItem6_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            FileClass.ExportExcel(this.gridControl1);
            //IList<string> col = new List<string>();//SelectAreaNameGroupByConn
            //IList<string> area = new List<string>();
            //FrmOutput frm = new FrmOutput();
            //AddCol(ref col, ref area);
            //frm.Column = col; frm.Area = area;
            //if (frm.ShowDialog() == DialogResult.OK)
            //{
            //    for (int i = 0; i < gridView1.Columns.Count; i++)
            //    {
            //        for (int j = 0; j < frm.Column.Count; j++)
            //        {
            //            if (frm.Column[j] == gridView1.Columns[i].Caption)
            //                gridView1.Columns[i].Visible = false;
            //        }
            //    }
            //    string conn = " and (";
            //    for (int j = 0; j < frm.VolLev.Count; j++)
            //    {
            //        if (j == frm.VolLev.Count - 1)
            //            conn += "L1=" + frm.VolLev[j] + ")";
            //        else
            //            conn += "L1=" + frm.VolLev[j] + " or ";
            //    }
            //    if (frm.Area.Count > 0)
            //        conn += " and (";
            //    for (int i = 0; i < frm.Area.Count; i++)
            //    {

            //        if (frm.Area[i] == "空")
            //            frm.Area[i] = "";
            //        if (i == frm.Area.Count - 1)
            //            conn += "AreaName='" + frm.Area[i] + "')";
            //        else
            //        {
            //            conn += "AreaName='" + frm.Area[i] + "' or ";
            //        }
            //    }
            //    //this.ctrlSubstation_Info1.RefreshDataOut(conn);
            //    //this.ctrlSubstation_Info1.CalcTotal(conn);
            //    FileClass.ExportExcel(this.gridControl1);
            //    for (int i = 0; i < gridView1.Columns.Count; i++)
            //    {
            //        gridView1.Columns[i].Visible = true;
            //    }
            //    //this.ctrlSubstation_Info1.RefreshData1();
            //    //this.ctrlSubstation_Info1.CalcTotal();
            //}
        }
コード例 #2
0
 private void barButtonItem2_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
 {
     FileClass.ExportExcel(this.ctrlProject_Sum1.GridControl);
 }
コード例 #3
0
ファイル: Form1ResultTJ.cs プロジェクト: github188/myitoppsp
 private void barButtonItem4_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
 {
     FileClass.ExportExcel(this.Text, _unitHeader, this.gridControl1);
 }