Ejemplo n.º 1
0
        private void btnExcelExport_Click(object sender, EventArgs e)
        {
            Control[] obj = null;
            obj    = new Control[1];
            obj[0] = spdData;

            CmnExcelFunction.ExportToExcelEx(obj, null, 1, "Production Output", "", true, false, false, -1, -1);
        }
Ejemplo n.º 2
0
 private void btnExcelExport_Click(object sender, EventArgs e)
 {
     if (spdData.Sheets[0].RowCount == 0)
     {
         MessageBox.Show(RptMessages.GetMessage("STD002", GlobalVariable.gcLanguage), "STD1501");
         return;
     }
     CmnExcelFunction.ExportToExcel(spdData, "Resource Analysis", "", true, false, false, -1, -1);
 }
Ejemplo n.º 3
0
 private void btnExcel_Click(object sender, EventArgs e)
 {
     try
     {
         CmnExcelFunction.ExportToExcel(lisFunc, "Function List In Web Report", "", true, false, false, -1, -1);
     }
     catch (Exception ex)
     {
         CmnFunction.ShowMsgBox("SEC1103.btnExcel_Click() : " + ex.ToString());
     }
 }
Ejemplo n.º 4
0
        /// <summary>
        /// ToExcel
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void btnExcelExport_Click(object sender, EventArgs e)
        {
            if (spdData.Sheets[0].RowCount == 0)
            {
                MessageBox.Show(RptMessages.GetMessage("STD002", GlobalVariable.gcLanguage), "STD1202");
                return;
            }

            Control[] obj            = null;
            string    sImageFileName = null;

            obj    = new Control[1];
            obj[0] = spdData;

            CmnExcelFunction.ExportToExcelEx(obj, sImageFileName, 1, "Production Output", "", true, false, false, -1, -1);
        }
Ejemplo n.º 5
0
        private void btnExcelExport_Click(object sender, EventArgs e)
        {
            if (ultraChart1.Visible == false && spdData.Sheets[0].RowCount == 0)
            {
                MessageBox.Show(RptMessages.GetMessage("STD002", GlobalVariable.gcLanguage), "STD1606");
                return;
            }

            Control[] obj            = null;
            string    sImageFileName = null;

            obj    = new Control[1];
            obj[0] = spdData;

            sImageFileName = Environment.GetFolderPath(Environment.SpecialFolder.MyPictures) + @"\myChart.png";
            CmnExcelFunction.ExportToExcelEx(obj, sImageFileName, 1, "Report Log", "", true, false, false, -1, -1);
        }
Ejemplo n.º 6
0
        private void udcReport003_ButtonExcelExportClick(object sender, EventArgs e)
        {
            Control[] obj        = null;
            string    sCondition = "";

            if (pnlCondition1.Visible == true)
            {
                if (udcPeriod1.Visible == true)
                {
                    sCondition += " From Date : " + " ";
                    sCondition += " To Date : " + " ";
                }
                if (udcCondition1.Visible == true)
                {
                    sCondition += udcCondition1.ConditionText + " : " + udcCondition1.Text;
                }
            }
            if (pnlCondition2.Visible == true)
            {
                if (udcCondition2.Visible == true)
                {
                    sCondition += udcCondition2.ConditionText + " : " + udcCondition2.Text;
                }
                if (udcCondition3.Visible == true)
                {
                    sCondition += udcCondition3.ConditionText + " : " + udcCondition3.Text;
                }
            }
            if (pnlCondition3.Visible == true)
            {
                if (udcCondition4.Visible == true)
                {
                    sCondition += udcCondition4.ConditionText + " : " + udcCondition4.Text;
                }
                if (udcCondition5.Visible == true)
                {
                    sCondition += udcCondition5.ConditionText + " : " + udcCondition5.Text;
                }
            }
            if (pnlCondition4.Visible == true)
            {
                if (udcCondition6.Visible == true)
                {
                    sCondition += udcCondition6.ConditionText + " : " + udcCondition6.Text;
                }
                if (udcCondition7.Visible == true)
                {
                    sCondition += udcCondition7.ConditionText + " : " + udcCondition7.Text;
                }
            }
            if (pnlCondition5.Visible == true)
            {
                if (udcCondition8.Visible == true)
                {
                    sCondition += udcCondition8.ConditionText + " : " + udcCondition8.Text;
                }
                if (udcCondition9.Visible == true)
                {
                    sCondition += udcCondition9.ConditionText + " : " + udcCondition9.Text;
                }
            }
            if (pnlCondition6.Visible == true)
            {
                if (udcCondition10.Visible == true)
                {
                    sCondition += udcCondition10.ConditionText + " : " + udcCondition10.Text;
                }
                if (udcCondition11.Visible == true)
                {
                    sCondition += udcCondition11.ConditionText + " : " + udcCondition11.Text;
                }
            }
            if (pnlCondition7.Visible == true)
            {
                if (udcCondition12.Visible == true)
                {
                    sCondition += udcCondition12.ConditionText + " : " + udcCondition12.Text;
                }
                if (udcCondition13.Visible == true)
                {
                    sCondition += udcCondition13.ConditionText + " : " + udcCondition13.Text;
                }
            }
            if (pnlCondition8.Visible == true)
            {
                if (udcCondition14.Visible == true)
                {
                    sCondition += udcCondition14.ConditionText + " : " + udcCondition14.Text;
                }
                if (udcCondition15.Visible == true)
                {
                    sCondition += udcCondition15.ConditionText + " : " + udcCondition15.Text;
                }
            }

            if (spdData_Sheet1.RowCount == 0)
            {
                return;
            }
            obj    = new Control[1];
            obj[0] = spdData;

            CmnExcelFunction.ExportToExcelEx(obj, "", 0, Title, sCondition, true, false, false, -1, -1);
        }