What is the process for splitting a string into segments every X number of characters? To put it in perspective, if I have an extremely lengthy string and want to divide it into parts of 1000 characters each, how can this be achieved when the content varies every time?
var string = <my text string containing thousands of characters>