Ejemplo n.º 1
0
        /*
         * Open FileDialog and
         * save data to excel file
         */
        private void BtnDataSaveToExcel_Click(object sender, RoutedEventArgs e)
        {
            if (lsData == null)
            {
                return;
            }

            ExcelWorker.Save(lsData, SaveType.All);
        }
        private void BtnLoadData_Click(object sender, RoutedEventArgs e)
        {
            WinForms.OpenFileDialog ofd = new WinForms.OpenFileDialog();
            ofd.Filter = "Excel File|*.xls";

            lsData =
                (ofd.ShowDialog() == WinForms.DialogResult.OK)
                    ? ExcelWorker.GetData(fileName = ofd.FileName)
                    : null;
        }
 private void BtnCreateExcelWorksheet_Click(object sender, RoutedEventArgs e)
 {
     ExcelWorker.CreateNewExcelWorksheet();
 }
 private void BtnSave_Click(object sender, RoutedEventArgs e)
 {
     ExcelWorker.Save(lsData, filePath, SaveType.Result);
 }