public ascx_LogViewer()
        {
            InitializeComponent();
            if (false == DesignMode)
            {
                DebugMsg.setRtbObject(rtbDebugMessages);

                cbErrorMessages.Checked = true;
                cbDebugMessages.Checked = true;
                cbInfoMessages.Checked  = true;
                //DI.log.error("Testing logging: Error Message");
                DI.log.debug("Testing logging: Debug Message");
                DI.log.info("Testing logging: Info Message");
            }
            //  this.Location = new Point(20,500);
        }
        public ascx_LogViewer()
        {
            try
            {
                InitializeComponent();
                if (false == DesignMode)
                {
                    if (PublicDI.log.LogRedirectionTarget == null || (PublicDI.log.LogRedirectionTarget is WinFormsUILog).isFalse())
                    {
                        PublicDI.log.LogRedirectionTarget = new WinFormsUILog();
                    }

                    cbErrorMessages.Checked = true;
                    cbDebugMessages.Checked = true;
                    cbInfoMessages.Checked  = true;

                    Load += (sender, e) =>
                    {
                        try
                        {
                            DebugMsg.setRtbObject(rtbDebugMessages);

                            "Testing logging: Debug Message".debug();
                            "Testing logging: Info Message".info();
                        }
                        catch (Exception ex)
                        {
                            ex.log("[in ascx_LogViewer onLoad]");
                        }
                    };
                }
            }
            catch (Exception ex)
            {
                ex.log("[in ascx_LogViewer]");
            }
            //  this.Location = new Point(20,500);
        }