Annoying Pipe Delimited File w/ Line Breaks
I have a text file that is pipe (|) delimited that also has line breaks in one of the fields which makes the file impossible to import into excel without errors.
For example, the format is like this:
NUMBER|NUMBER|TEXTFIELD CR LF
NUMBER|NUMBER|TEXTFIELD CR LF
NUMBER|NUMBER|TEXTFIELD CR LF
CONTINUATION OF TEXT CR LF
NUMBER|NUMBER|TEXTFIELD CR LF
CR LF
CR LF
CONTINUATIONOFTEXT CR LF
NUMBER|NUMBER|TEXTFIELD CR LF
I am trying to write a macro that will open that text file and export back out a text file that will eliminate all of the carriage return line feed breaks that are putting that 3rd field onto the next line so that the output data would look like this:
NUMBER|NUMBER|TEXTFIELD CR LF
NUMBER|NUMBER|TEXTFIELD CR LF
NUMBER|NUMBER|TEXTFIELD CONTINUATION OF TEXT CR LF
NUMBER|NUMBER|TEXTFIELD CONTINUATIONOFTEXT CR LF
NUMBER|NUMBER|TEXTFIELD CR LF
Has anyone done anything like this before?
Posted Nov 15, 2016, 5:43 PM UTC
717