duheng
2024-12-19 3af811d30c93995e2500bdd2f3795be77cc1a519
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
//编辑原始的性能曲线
using Yw.Vmo;
 
namespace HStation.WinFrmUI
{
    public partial class ImportPumpPerform2dByExcelCtrl : DevExpress.XtraEditors.XtraUserControl
    {
        public ImportPumpPerform2dByExcelCtrl()
        {
            InitializeComponent();
        }
 
        //选择Excel文件
        private void btnExcelFilePath_ButtonClick(object sender, DevExpress.XtraEditors.Controls.ButtonPressedEventArgs e)
        {
            if (e.Button.Tag.ToString() == "Import")
            {
                var dlg = new System.Windows.Forms.OpenFileDialog();
                dlg.Filter = "EXCEL 文件(*.xls)|*.xls";
                dlg.CheckFileExists = true;
                if (dlg.ShowDialog() != System.Windows.Forms.DialogResult.OK)
                    return;
                this.btnExcelFilePath.Text = dlg.FileName;
                this.pumpChartExcelImportCtrl1.SetBindingData(btnExcelFilePath.Text);
            }
            else if (e.Button.Tag.ToString() == "Download")
            {
            }
        }
 
        /// <summary>
        /// 获取数据
        /// </summary>
        /// <returns></returns>
        public PhartDiagramExGraphListVmo Get()
        {
            return this.pumpChartExcelImportCtrl1.Get();
        }
    }
}