public InstallCRANPackage ( ) : |
||
리턴 |
protected override void OnExecute(object param) { Window1 appwindow = LifetimeService.Instance.Container.Resolve<Window1>(); try { appwindow.setLMsgInStatusBar("Please wait ... Installing package(s) from CRAN ..."); PackageHelperMethods phm = new PackageHelperMethods(); UAReturn r = phm.InstallCRANPackage();// InstallCRANPackage(); if (r != null) { if (r.Success) { SendToOutputWindow("Install Package from CRAN", r.CommandString); } else if (!r.Success) { SendToOutputWindow("Install Package from CRAN", r.Error); } } else { if(r != null) // if user didn't press 'Cancel' SendToOutputWindow("Error Installing CRAN Package", "Package names are case sensitive. Please check your packgename.", false); } } catch (Exception ex) { MessageBox.Show("Error while loading package.", "Error Occurred!"); logService.WriteToLogLevel("Error:", LogLevelEnum.Error, ex); } appwindow.setLMsgInStatusBar(""); }
protected override void OnExecute(object param) { Window1 appwindow = LifetimeService.Instance.Container.Resolve <Window1>(); try { appwindow.setLMsgInStatusBar(BSky.GlobalResources.Properties.Resources.PlzWait + " " + BSky.GlobalResources.Properties.Resources.InstallingFromCRAN); PackageHelperMethods phm = new PackageHelperMethods(); UAReturn r = phm.InstallCRANPackage();// InstallCRANPackage(); if (r != null) { if (r.Success) { SendToOutputWindow(BSky.GlobalResources.Properties.Resources.InstallingFromCRAN, r.CommandString, false); } else if (!r.Success) { SendToOutputWindow(BSky.GlobalResources.Properties.Resources.InstallingFromCRAN, r.Error, false); } } else { if (r != null) // if user didn't press 'Cancel' { SendToOutputWindow(BSky.GlobalResources.Properties.Resources.ErrInstallingFromCRAN, BSky.GlobalResources.Properties.Resources.RPkgNameCaseSensitive, false); } } } catch (Exception ex) { MessageBox.Show(BSky.GlobalResources.Properties.Resources.ErrLoadingRPkg2, BSky.GlobalResources.Properties.Resources.ErrorOccurred); logService.WriteToLogLevel("Error:", LogLevelEnum.Error, ex); } appwindow.setLMsgInStatusBar(""); }
protected override void OnExecute(object param) { Window1 appwindow = LifetimeService.Instance.Container.Resolve <Window1>(); try { appwindow.setLMsgInStatusBar("Please wait ... Installing package(s) from CRAN ..."); PackageHelperMethods phm = new PackageHelperMethods(); UAReturn r = phm.InstallCRANPackage();// InstallCRANPackage(); if (r != null) { if (r.Success) { SendToOutputWindow("Install Package from CRAN", r.CommandString); } else if (!r.Success) { SendToOutputWindow("Install Package from CRAN", r.Error); } } else { if (r != null) // if user didn't press 'Cancel' { SendToOutputWindow("Error Installing CRAN Package", "Package names are case sensitive. Please check your packgename.", false); } } } catch (Exception ex) { MessageBox.Show("Error while loading package.", "Error Occurred!"); logService.WriteToLogLevel("Error:", LogLevelEnum.Error, ex); } appwindow.setLMsgInStatusBar(""); }