Tell me more ×
Stack Overflow is a question and answer site for professional and enthusiast programmers. It's 100% free, no registration required.

In Powershell how would I convert a string with a varying length of characters to an array formatted to a specific number of characters per item? Example using 10 characters per item in the array:

string: 012345678901234567890123456789

array:

0123456789
0123456789
0123456789

So the first item in the array would be the first 10 characters of the string, the second item the next 10, and so on. Thanks.

share

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.