What's the best way of adding spaces between strings
myString = string.Concat("a"," ","b")
or
myString = string.Concat("a",Chr(9),"b")
I am using stringbuilder to build an XML file and looking for something efficient.
Thanks
Edit ~ Language VB.NET
Create your XML file with the XmlDocument class. Your wasting your time creating a string from scratch.
String.Join is a static method that can take the separator (in this case, " ") and an array of strings.
string sentence = String.Join(" ", new string[] { "The", "quick", "brown", "fox" });
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With