Example #1
0
        public void CMDprintError(string value)
        {
            string log = string.Format("[{0}][Error]{1}\r\n", DateTime.Now.ToLongTimeString(), value);

            try
            {
                CmdrichTextBox.AppendText(log);
            }
            catch (Exception e)
            {
                this.Invoke(new Action(delegate
                {
                    CmdrichTextBox.AppendText(log);
                }));
            }
        }
Example #2
0
 private void CmdrichTextBox_TextChanged(object sender, EventArgs e)
 {
     CmdrichTextBox.SelectionStart = CmdrichTextBox.Text.Length; //Set the current caret position at the end
     CmdrichTextBox.ScrollToCaret();                             //Now scroll it automatically
 }