The Stringbulider sub may have a string concatenation error. There may be “hidden” data in the file that is read into the string. Generally a read-buffer reads numeric data as numeric and this includes an implied “+” sign which is not visible. This is common to most all programming languages
The error that occurs at “101” may also have occurred at “10,” but it didn’t display because it only displays if the number is palindromic. Temporarily set the output to screen-print all converted numbers to see if this is the case. If it is, then step through the logic to find and correct the length error.
The error at 227 is probably cause by rubbish in the input file. There may be a trailing decimal following the number. This will cause the byte size to jump by 2, because the input read buffer will treat it as a floating point number, instead of an integer.
The fix for these errors is usually trivial. It may require stepping through the logic, examining every parameter, checking for string length, and for residual data that may remain in a buffer.
GA