Kiti Posted June 14, 2008 Share Posted June 14, 2008 (edited) How can I get a substring? It should be something like: $a = the substring $b = "string" $a = b.substring (2,6) ;$a would have to be "ring" Does AutoIt support substrings? Edit: I know about _StringSplit, but is there a more direct way, to select the number in a word of the first and last character your substring must have? Edit2: Ok, I've got it I should use StringTrimLeft/Right. Sorry for the useless topic. Edited June 14, 2008 by Kiti Think outside the box.My Cool Lego Technic Website -- see walking bipeds and much more!My YouTube account -- see cool physics experimentsMy scripts:Minesweeper bot: Solves advanced level in 1 second (no registry edit), very improved GUI, 4 solving stylesCan't go to the toilet because of your kids closing your unsaved important work? - Make a specific window uncloseableCock Shooter Bot -- 30 headshots out of 30 Link to comment Share on other sites More sharing options...
cppman Posted June 14, 2008 Share Posted June 14, 2008 How can I get a substring? It should be something like: $a = the substring $b = "string" $a = b.substring (2,6) ;$a would have to be "ring" Does AutoIt support substrings? Edit: I know about _StringSplit, but is there a more direct way, to select the number in a word of the first and last character your substring must have? Edit2: Ok, I've got it I should use StringTrimLeft/Right. Sorry for the useless topic. You should use StringMid. That function is specifically meant for what you are doing. Miva OS Project Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now