I need to remove the blinking vertical line indicating the place where text would be inserted, even if I click on the TextBox.
Note that textbox
is already ReadOnly = true
and I don't want to disable it.
Any idea? Thanks!
I finally found two working ways for solving this:
1. Send textbox focus away
Sending focus to another component on Form initialization:
public Form1(){
InitializeComponent();
textBox1.Enter += (s, e) => { textBox1.Parent.Focus(); };
}
2. Create a Label and customize it
In the label properties, set:
BorderStyle = Fixed3D
BackColor = Window
AutoSize = False
And resize the label in the form design view