public override void Run(object sender, System.EventArgs e) { DF3DApplication app = (DF3DApplication)this.Hook; if (app == null || app.Current3DMapControl == null) { return; } if (!app.IsInit3DControl) { XtraMessageBox.Show("三维空间初始化失败!", "提示"); return; } try { Layer3DPlanTreePad pad = UCService.GetContent(typeof(Layer3DPlanTreePad)) as Layer3DPlanTreePad; if (pad == null) { return; } app.Workbench.SetStatusInfo("规划数据加载中…"); SplashScreenManager.Default.SendCommand(null, "开始加载三维规划数据......"); string str3DPlanDataConn = Config.GetConfigValue("3DPlanDataConnStr"); if (!string.IsNullOrEmpty(str3DPlanDataConn)) { IConnectionInfo ci = new ConnectionInfo(); ci.FromConnectionString(str3DPlanDataConn); DataUtils.Add3DPlanData(ci, pad, pad.TreeList); } } catch (Exception ex) { } }