DOS:删除空格
我正在执行下面的脚本,但它不起作用,因为之间有空格。下面是脚本:
move C:\abc\d\System Table\Table Six (Top)\LogFiles*.jpg D:\Archive\
我们怎样才能消除 & 之间的空格?确保系统能够理解,以便将所有 jpg 文件移动到 D:\Archive
Regards, 轨道
I am executing the below script, but it is not working as there are spaces in between. Below is the script:
move C:\abc\d\System Table\Table Six (Top)\LogFiles*.jpg D:\Archive\
How can we eliminate the spaces in between & make sure the system understands so that it moved all jpg files to D:\Archive
Regards,
Orbit
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
将文件名引起来。这向命令行解析器表明引号之间的所有内容都是单个标记
Place quotes around the file names. That indications to the command line parser that everything between the quotes is a single token
将长文件名用双引号引起来。
Wrap long filenames in double quotes.
有关更多 DOS 批处理文件命令和语法,http://www.dostips.com/ 有一个相当不错的列表和很多例子。
作为替代方案,您可以使用 8.3 表示并删除空格(尽管我更喜欢引号和空格)。
如果您有其他类似命名的目录,
~?
可能会有所不同。For more DOS batch file commands and syntax, http://www.dostips.com/ has a pretty good list and lots of examples.
As an alternative, you could use the 8.3 representation and remove the spaces (though I prefer the quotes and spaces).
If you have other similarly named directories, the
~?
could be different.