public Help2RegisterClass()
        {
            try
            {
                registerSession = new HxRegisterSessionClass();
                registerSession.CreateTransaction("");

                register = (IHxRegister)registerSession.GetRegistrationObject(HxRegisterSession_InterfaceType.HxRegisterSession_IHxRegister);
                filters  = (IHxFilters)registerSession.GetRegistrationObject(HxRegisterSession_InterfaceType.HxRegisterSession_IHxFilters);
                plugins  = (IHxPlugIn)registerSession.GetRegistrationObject(HxRegisterSession_InterfaceType.HxRegisterSession_IHxPlugIn);
            }
            catch (System.Runtime.InteropServices.COMException)
            {
            }
        }
        public Help2RegisterClass()
        {
            try
            {
                registerSession = new HxRegisterSessionClass();
                registerSession.CreateTransaction("");

                register = (IHxRegister)registerSession.GetRegistrationObject(HxRegisterSession_InterfaceType.HxRegisterSession_IHxRegister);
                filters  = (IHxFilters)registerSession.GetRegistrationObject(HxRegisterSession_InterfaceType.HxRegisterSession_IHxFilters);
                plugins  = (IHxPlugIn)registerSession.GetRegistrationObject(HxRegisterSession_InterfaceType.HxRegisterSession_IHxPlugIn);
            }
            catch (System.Runtime.InteropServices.COMException)
            {
            }
        }
Beispiel #3
0
        public HelpRegistrar()
        {
            try
            {
                _hxRegisterSession = new HxRegisterSessionClass();
                _hxRegisterSession.CreateTransaction("");

                _hxRegister = (IHxRegister)_hxRegisterSession.GetRegistrationObject(
                    HxRegisterSession_InterfaceType.HxRegisterSession_IHxRegister);
                _hxFilters = (IHxFilters)_hxRegisterSession.GetRegistrationObject(
                    HxRegisterSession_InterfaceType.HxRegisterSession_IHxFilters);
                _hxPlugins = (IHxPlugIn)_hxRegisterSession.GetRegistrationObject(
                    HxRegisterSession_InterfaceType.HxRegisterSession_IHxPlugIn);
            }
            catch (COMException)
            {
            }
        }
Beispiel #4
0
        protected virtual void Dispose(bool disposing)
        {
            if (disposing)
            {
                if (_hxRegisterSession != null)
                {
                    // PLEASE DO NOT CHANGE OR REMOVE THAT!!!

                    _hxRegisterSession.CommitTransaction();

                    // It's very important to close the connection to the Help 2.0
                    // environment. Trust me. I cannot explain because I don't know
                    // anything about the Help 2.0 API. I was experimenting with the
                    // Help 2.0 system and I knocked it out so many times ...

                    _hxRegisterSession = null;
                }
            }
        }