Splitting string into individual characters

this should be easy but I couldn’t find anything that would let me split a string into all it’s individual characters
ofSplitstring(string,"") returns only one string back. so there should be some other solution, any ideas?

a string is already a collection of characters so it’s not very useful to have a function to do that, you can access the individual caracters like:


where i goes from 0 to someString.size()-1

1 Like

thanks. it would be great if there was a mention about that somewhere in the documentation. At least I couldn’t find it

that’s standard c++ nothing specifically related to OF, that’s why there’s nothing in the documentation but yes we should think about how to have some docs that explain basics about c++ in the reference.