Fixed length data

General questions about using TextPad

Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard

Post Reply
Michael Cook

Fixed length data

Post by Michael Cook »

I have a fixed length data file with 1,442 records and no carriage returns because length determines where a new record starts.

Is there any way to get TextPad to insert a carriage return every 100 characters?
Andreas

Re: Fixed length data

Post by Andreas »

Replace

.\{100,100\}

by

&\n

(make sure, Regex is ON)
(this assumes non-POSIX Syntax for Regex, if you have POSIX syntax configured don't use the backslashes with the {}
Michael Cook

Re: Fixed length data

Post by Michael Cook »

It worked!
Thank you very much for the quick and correct response.

Actually, it turned out that the record length is 150.
So I replaced "100" with "150" and it worked.
Post Reply