I am trying to extract a sub string from a string using Visual Basic.
This is what I have tried:
Dim TestString = "Aberdeen, 1"
for i = 0 to TestString.length-1
debug.print(teststring(i))
next
What I would like to do is loop through the TestString so that it only extracts and prints the words "Aberdeen" WITHOUT the comma and the number 1. So far, all the characters are getting added.
Any help much appreciated.
TestStringhave other values? Should it simply stop when it finds a comma?