System.Windows.Forms.TextBoxBase.AppendText C# (CSharp) Method

AppendText() public method

public AppendText ( string text ) : void
text string
return void
		public void AppendText (string text)
		{
			// Save some cycles and only check the Text if we are one line
			bool is_empty = Lines.Length == 1 && Text == String.Empty; 
			
			m_helper.TextView.Value += text;
			
			if (!is_empty)
				ScrollToCaret ();

			//
			// Avoid the initial focus selecting all when append text is used
			//
			has_been_focused = true;

			Modified = false;
			OnTextChanged(EventArgs.Empty);
		}
		

Usage Example

Example #1
0
 public static void AppendText(TextBoxBase control, string text)
 {
     if (control.InvokeRequired)
         control.Invoke(new AppendTextDelegate(AppendText), control, text);
     else
         control.AppendText(text);
 }
All Usage Examples Of System.Windows.Forms.TextBoxBase::AppendText