Menu

#8 replace backslash by forward slash in a string containing a windows path

v1.0 (example)
open
nobody
None
7
2019-01-15
2016-07-26
Marc Smet
No

a text file contains a string like this:

"C:\Program Files/Hewlett-Packard/Operations Orchestration" (actually the original string before substitution is like this ""%ProgramFiles%/Hewlett-Packard/Operations Orchestration"")

I'm trying to replace the "\" with a "/" using the following cmd:

fart.exe %ootkdir%\temp.txt "\" "/"

which doesn't work :-(
All help hihgly appreciated!

Related

Support Requests: #8

Discussion

  • Lionello Lunesu

    Lionello Lunesu - 2016-07-28

    You'll need two backslashes, because of the way cmd works.

    On Tue, Jul 26, 2016 at 11:13 PM, Marc Smet msmet@users.sf.net wrote:


    Status: open
    Group: v1.0 (example)
    Created: Tue Jul 26, 2016 03:13 PM UTC by Marc Smet
    Last Updated: Tue Jul 26, 2016 03:13 PM UTC
    Owner: nobody

    a text file contains a string like this:

    "C:\Program Files/Hewlett-Packard/Operations Orchestration" (actually the
    original string before substitution is like this
    ""%ProgramFiles%/Hewlett-Packard/Operations Orchestration"")

    I'm trying to replace the "\" with a "/" using the following cmd:

    fart.exe %ootkdir%\temp.txt "\" "/"

    which doesn't work :-(
    All help hihgly appreciated!


    Sent from sourceforge.net because you indicated interest in
    https://sourceforge.net/p/fart-it/support-requests/8/

    To unsubscribe from further messages, please visit
    https://sourceforge.net/auth/subscriptions/

    --
    L.

     

    Related

    Support Requests: #8

  • toni

    toni - 2019-01-15

    Hi i have same question but not work

    i create file list with dir command and i get

    C:\Folder\Folder2\Folder3\File.txt

    so i want all \ convert to / how can do this?

    i try with \ / and "\" "/" but not working. Can you please write syntax.

     

Log in to post a comment.

MongoDB Logo MongoDB