How do i convert multiple lines from a notepad.txt into a single lines?
VB6 - multiple lines from a notepad.txt into a single lines?
Collapse
X
-
Tags: None
-
To convert multiple lines from a notepad.txt file into a single line, you can follow these steps:
1. Open the notepad.txt file in a text editor.
2. Select and copy the contents of the file.
3. Open a new blank document or text editor window.
4. Paste the copied text into the new document.
5. Replace line breaks with a space or any other separator of your choice. The method for replacing line breaks may vary depending on the text editor you are using.
> In most text editors, you can use the find and replace function (typically Ctrl + H or Command + H) to find line breaks (represented as "\n" or "\r\n") and replace them with a space or another desired separator.
> If your text editor supports regular expressions, you can search for "\r?\n" (for Windows-style line breaks) or "\n" (for Unix-style line breaks) and replace them with a space or desired separator.
6. Once you've replaced the line breaks, you should have the text from the notepad.txt file in a single line.
7. Save the modified text as a new file or overwrite the original notepad.txt file.
Remember to keep a backup of the original file before making any modifications to ensure you don't lose any data.Comment
-
The use of backslash variables is not bad, rather than the HTML "<BR>" of course.
The reason I went with the "Replace" function is that this was raised as a VB6 Question :-)
This suggests that the question was intended to achieve a programmatic response in VB6.
But yes, I do prefer your backslash variables :-)
Cheers,
KevinComment
Comment