Is it possible to add a tab character into a textblock? It's a textblock in Xaml, but i'm adding the text in code, so it has to be done there. Is there any action like "Environment.NewLine", but for the "Tab" character?
Thanks in advance.
Is it possible to add a tab character into a textblock? It's a textblock in Xaml, but i'm adding the text in code, so it has to be done there. Is there any action like "Environment.NewLine", but for the "Tab" character?
Thanks in advance.
Or a more .Net-y way:
Convert.ToChar(Keys.Tab)
ControlChars.Tab
is another option. But there's nothing wrong with using the vbTab
constant. It's just as much .NET as everything else. The compiler output will be the same as the C# compiler with the \t
escape.
You can also use:
ControlChars.Tab
Sure just use:
Chr(9)
Example:
TextBox1.Text = "hey" + Chr(9) + "you"