using ESRI.ArcGIS.Controls; using KGIS.Framework.Commands; using KGIS.Framework.Utils.Helper; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using KUI.Windows; using Kingo.Plugin.General.ViewDTBJK; namespace Kingo.Plugin.General.Commands { /// /// 批量导入导出 /// public class CmdTaskExportAndImport : BaseMenuCommand { private UCJKResultExport ucJKResultExport = null; private IHookHelper m_hookHelper { get; set; } public override void OnClick() { try { if (ucJKResultExport == null) { ucJKResultExport = new UCJKResultExport(true) { hookHelper = this.m_hookHelper, Title = "批量导入导出", Width = 900, Height = 450, WindowStartupLocation = System.Windows.WindowStartupLocation.CenterScreen }; ucJKResultExport.Closed += UcJKResultExport_Closed; ucJKResultExport.BindData(); ucJKResultExport.ShowInMainForm(false); } } catch (Exception ex) { KGIS.Framework.Utils.LogAPI.Debug("建库成果导出界面初始化异常:" + ex.Message); MessageHelper.ShowError("建库成果导出界面初始化异常:" + ex.Message); } finally { } } private void UcJKResultExport_Closed(object sender, EventArgs e) { try { if (ucJKResultExport != null) { ucJKResultExport.Close(); } ucJKResultExport = null; } catch (Exception ex) { KGIS.Framework.Utils.LogAPI.Debug(ex); } } public override void OnCreate(object Hook) { try { if (m_hookHelper == null) { m_hookHelper = new HookHelperClass { Hook = Hook }; } } catch { m_hookHelper = null; return; } } } }