命令行在引号内传递引号 [英] Command line passing quotes within quotes

查看:188
本文介绍了命令行在引号内传递引号的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在寻找解决方案,但是找不到。不确定是否可能。

I've been searching for a solution to this but couldn't find one. Not sure if its possible.

我可以传递到命令行执行中,该命令在bat文件中传递一个以输入文件作为参数的bat文件吗?

Can I pass into command-line execution that passes a in a bat file which has an input file as its arguments?

因此在命令行中,它看起来像这样:

So from the command-line it'll look like this:

C:\run.exe "C:\space folder\run.bat "C:\space folder\input.txt""

问题出在带空格的文件夹中,因此必须在其中加上
引号。

The problem is with the folders that has spaces so the quotes are required to be in there.

推荐答案

尝试一下:

C:\run.exe "C:\space folder\run.bat \"C:\space folder\input.txt\""

这是一个链接,您可以看到所有转义符
http://www.robvanderwoude.com /escapechars.php

And here is a link that you can see all escape characters http://www.robvanderwoude.com/escapechars.php

这篇关于命令行在引号内传递引号的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆