Thanks for responding, I had changed that variable, but that wasn't what was required, it was the line:
sprintf (split, "rec%5d", wrBlock+1);
Changed the 5 to a 9. But there loads of other problems too, it created so many files that Linux was struggling with everything. I had to write a fairly...