Esempio n. 1
0
        public override void Stop()
        {
            COMHelper.ShutdownCOMApplication(this.args.CategoryName);

            if (COMHelper.HasCOMComponent(this.args.AppName))
            {
                COMHelper.DeleteCOMComponent(this.args.AppName);
            }

            COMHelper.ShutdownCOMApplication(this.args.CategoryName);
        }
Esempio n. 2
0
        public override void ValidateArguments()
        {
            base.ValidateArguments();

            if (string.IsNullOrEmpty(this.args.CategoryName))
            {
                throw new ArgumentNullException("categoryName", "categoryName can not be null or empty");
            }

            if (!this.args.NoStop && !COMHelper.HasCOMComponent(this.args.AppName))
            {
                throw new ArgumentException(this.args.AppName + " component could not be found", "appName");
            }
        }