Navigation

    Community

    • Login
    • Search
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    Can't open files with spaces in name

    General Discussion
    3
    4
    274
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • toubept
      toubept last edited by

      If a file is named something like “myfile copy.php”, it won’t open. Notepad++ displays three messages asking to create the file. Each message has part of the original name, like “myfile”, " " and “copy”. I have a program that creates names like that when I copy them. Is there a way to load them without editing the names?

      1 Reply Last reply Reply Quote 0
      • Michael Vincent
        Michael Vincent last edited by

        How are you trying to open it? Right-click and open from Explorer should work just fine. You just need to put double-quotes around the name from a command prompt.

        C:\> notepad++.exe "myfile copy.php"
        
        1 Reply Last reply Reply Quote 2
        • PeterJones
          PeterJones last edited by

          @toubept ,

          My guess is that your file association is wrong, and is running notepad++ with the arg %1 rather than "%1" (with the quotes).

          You probably should search through your registry, and find instances of notepad++ or notepad++.exe, looking for any that don’t put the quotes around the %1; any that you find, you should change to have the quotes.

          It’s like to look something like:

          • "c:\program files\notepad++\notepad++.exe" %1 => "c:\program files\notepad++\notepad++.exe" "%1"
          • "c:\program files (x86)\notepad++\notepad++.exe" %1 => "c:\program files (x86)\notepad++\notepad++.exe" "%1"

          … or similar

          1 Reply Last reply Reply Quote 3
          • toubept
            toubept last edited by

            @PerterJones That was it. Thank you very much. :)

            1 Reply Last reply Reply Quote 2
            • First post
              Last post
            Copyright © 2014 NodeBB Forums | Contributors