problems with CR/LF code

I export a txt file with ";" delimiters from an Access 2007 database. This results in a text file that I can open in for example notepad. Notepad recognizes the end of the line command apparently, because I can see my data nicely line by line

Whithout changing anything I do the same export, but this time I open it in Windows 7 with the text editor (not sure if it is called Notepad), the file shows squares instead of a line break. How can I adjust my export to txt to force an CR/LF at the end of each record? I read somewhere that VB constants are version dependent. Should I choose UTF8? or ASCII so that Windows 7 understands my end of line?

any one knows about this problem?

Answer
Answer

Use an open source program, Notepad++.

  1. Open your text file in Notepad++. Then navigate to menu View > Show Symbols > Show all characters.
  2. Highlight one of those squares in your text, then copy it to clipboard.
  3. Press Ctrl+H.
  4. Inside "Find what:" textbox, paste (Ctrl+V).
  5. Inside "Replace with:", type \r\n
  6. In search options, choose "Extended (\r, \n, \t, \0, \x...)".
  7. Replace All.
  8. Verify that now you can see each line ends with CR LF box.
  9. Navigate to menu View > Show Symbols > uncheck show all characters.
  10. Save your file if all worked fine.

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

 
 

Question Info


Last updated September 19, 2019 Views 10,549 Applies to: