Jun 11
21
Parsing A Few Characters in A String – VB.Net
Leave a comment »
If you need to parse just a few characters from a string, you can easily do that in the code-behind like this:
MyVariable = VariableName.Substring(1,3)
This gets the first through the third character in the string and places it in MyVariable. Note that the starting position of the variable is 0 so the true first characters would be picked up if you used VariableName.Substring(0,3).