1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

How to remove space from every line in a text file ?

Discussion in 'BlackHat Lounge' started by MethShow, Jan 26, 2011.

  1. MethShow

    MethShow Registered Member

    Joined:
    Jan 24, 2011
    Messages:
    57
    Likes Received:
    2
    Hey, anyone know how to remove space from every line in a text file ?

    I have a text file eg:

    texttexttext texttexttext
    texttexttext texttexttext

    there is 1 space in everyline, anyone know a tool that will remove space from every line ?

    Thanks
     
  2. Chees

    Chees Regular Member

    Joined:
    Apr 16, 2010
    Messages:
    476
    Likes Received:
    151
    open it notepad. edit > replace
    find what: put space
    replace with: dont put anything
    hit replace all
     
  3. MethShow

    MethShow Registered Member

    Joined:
    Jan 24, 2011
    Messages:
    57
    Likes Received:
    2
    It doesn't work, it works when I put space manually, but this is the text I copied from excel, and the notepad doesn't recognise it as space, it says doesn't find.There is only 1 space, I tried 1, 2, 3 space, it doesn't work.

    Any other method or tool u know.

    THanks
     
  4. webmast

    webmast Regular Member

    Joined:
    Dec 18, 2010
    Messages:
    337
    Likes Received:
    238
    I use Notepad++ to remove spaces like that.
    No instructions though. This is BHW, not JustinBieber . com :D
     
    Last edited: Jan 26, 2011
  5. MethShow

    MethShow Registered Member

    Joined:
    Jan 24, 2011
    Messages:
    57
    Likes Received:
    2
    Yes, I got it, I use nvu and it works !