Software that can replace spaces with line breaks?

8 replies
I've tried using find and replace with Notepad++ and PSPad and I couldn't get it to work with them.

I could make all characters visible in Notepad++ then was able to select the line break character, but it wouldn't copy and paste into the replace box.

Also tried Notepad and Wordpad but they didn't even come close.

But maybe there is another way of doing it with one of those programs that I just didn't think of. Or maybe there is another program that can do it?

baffled
#breaks #line #replace #software #spaces
  • Profile picture of the author snapcontent
    In word, replace space with ^13

    in PHP str_replace(" ", "\n", $s);
    {{ DiscussionBoard.errors[2706362].message }}
  • Profile picture of the author Kurt
    Originally Posted by Lloyd Buchinski View Post

    I've tried using find and replace with Notepad++ and PSPad and I couldn't get it to work with them.

    I could make all characters visible in Notepad++ then was able to select the line break character, but it wouldn't copy and paste into the replace box.

    Also tried Notepad and Wordpad but they didn't even come close.

    But maybe there is another way of doing it with one of those programs that I just didn't think of. Or maybe there is another program that can do it?

    baffled

    Hey Lloyd,

    I think for Notetab it's:
    Find:
    (blank space)

    Replace
    ^p

    Maybe with a capital P = ^P

    I don't think you need to worry about viewing the invisible characters.
    Signature
    Discover the fastest and easiest ways to create your own valuable products.
    Tons of FREE Public Domain content you can use to make your own content, PLR, digital and POD products.
    {{ DiscussionBoard.errors[2706405].message }}
  • Profile picture of the author SteveJohnson
    Easy way in Notepad++:

    First, you'll need to verify the line break style that you need. Select View > Show Symbol > Show End of Line from the menu, or click the paragraph symbol in the toolbar. Look at the the end of a line for the type of line break used. Three possibilities: LF, CR, or CR LF. Unix/Linux uses LF, Mac files use CR, Windows uses both.

    Bring up find/replace dialog (ctrl-h). In the Find box, just hit the spacebar. Hit the tab key to switch to the replace box. In the box, use one of the following, depending on your EOL type: \n for LF (that's a lower-case L, btw), \r for CR, or \r\n for CR LF.

    Click the "Extended" radio button in the Search Options select box, then click your choice of Find Next/Replace or Replace All buttons.

    Signature

    The 2nd Amendment, 1789 - The Original Homeland Security.

    Gun control means never having to say, "I missed you."

    {{ DiscussionBoard.errors[2706451].message }}
  • Profile picture of the author Lloyd Buchinski
    Sincere thanks. I thought of another way when I woke up this am but these are great info. I don't get along very well with Word so I didn't even try it there but nice to know it can do that.

    Kurt, I meant to thank one of your posts in another thread but just smacked the button on both of your posts here instead. Saves having to look for the original again.

    ../lloyd
    Signature

    Do something spectacular; be fulfilled. Then you can be your own hero. Prem Rawat

    The KimW WSO

    {{ DiscussionBoard.errors[2706829].message }}
  • Profile picture of the author Viral
    Lloyd, what did you end up doing? i need help with it
    {{ DiscussionBoard.errors[5552976].message }}
  • Profile picture of the author agc
    Editplus also supports search and replace w/ control characters (\n) and also regular expressions (also referred to as "line noise").

    And there's a free trial version.
    {{ DiscussionBoard.errors[5553170].message }}
  • Profile picture of the author Lloyd Buchinski
    I've done this quite a few times now using the SteveJohnson technique, but I had to use \r for the line break character on my machines.

    The Word replacement is probably the easiest. Just tap the space bar once in the find box, and in the replace box use ^13

    That does the job.
    Signature

    Do something spectacular; be fulfilled. Then you can be your own hero. Prem Rawat

    The KimW WSO

    {{ DiscussionBoard.errors[5554663].message }}

Trending Topics