[CMD echo 求救]
时间:2013-11-12
来源:互联网
Example
set string1="a&b"
echo %string1%
Result: a
点先可以echo出到a&b?
Thanks
set string1="a&b"
echo %string1%
Result: a
点先可以echo出到a&b?
Thanks
作者: zone1326 发布时间: 2013-11-12
引用:原帖由 zone1326 於 2013-10-17 10:38 AM 发表
Example
set string1="a&b"
echo %string1%
Result: a
点先可以echo出到a&b?
Thanks
But my os...Example
set string1="a&b"
echo %string1%
Result: a
点先可以echo出到a&b?
Thanks
C:\>set string1="a&b"
C:\>echo %string1%
"a&b"
Anyway, your answer is:
C:\>set string1=a^^^&b
C:\>echo %string1%
a&b
作者: 111x111=12321 发布时间: 2013-11-13
Thank you.
There is another problem
Example
set string1="a& b"
I want the echo result = a& b, is it possible?
I use %string1:~1,1% to remove the first and last "
But when I echo, I get result a only
I tried to set string1="a^^^& b" also but not successful
There is another problem
Example
set string1="a& b"
I want the echo result = a& b, is it possible?
I use %string1:~1,1% to remove the first and last "
But when I echo, I get result a only
I tried to set string1="a^^^& b" also but not successful
作者: zone1326 发布时间: 2013-11-13
引用:原帖由 zone1326 於 2013-10-17 03:52 PM 发表
Thank you.
There is another problem
Example
set string1="a& b"
I want the echo result = a& b, is it possible?
I use %string1:~1,1% to remove the first and last "
But when I echo, I get resu ...
试新野你要简单d, 排除互相影响因素, 况且你自己好乱...Thank you.
There is another problem
Example
set string1="a& b"
I want the echo result = a& b, is it possible?
I use %string1:~1,1% to remove the first and last "
But when I echo, I get resu ...
点解多左个space???
你想trim个 " 就只试佢,
唔好沟埋 &, 个 & 系麻烦野, 因为佢本身另有用途.
其实个 " 亦正正系本身有用途.
作者: 111x111=12321 发布时间: 2013-11-13
set string1=a^^^&b
作者: dynix.tw2 发布时间: 2013-11-13
其实系咁
我本身有个text file (a.txt), 入面有两行
hello & good day-morning
-
我要将第二行果个- 转做另一个string
我试用for /f 去check每行第一个char系唔系-, 如果系就转佢做另一个string 之后要output落个新txt file
如果第一个char唔系- 就唔驶转任何野
因为试左如果有space, 佢净系会read到space之前既野, 所以我行for /f 果阵每行头尾都加左"
所以最尾又要trim返走头尾"
自己都写到乱晒
我本身有个text file (a.txt), 入面有两行
hello & good day-morning
-
我要将第二行果个- 转做另一个string
我试用for /f 去check每行第一个char系唔系-, 如果系就转佢做另一个string 之后要output落个新txt file
如果第一个char唔系- 就唔驶转任何野
因为试左如果有space, 佢净系会read到space之前既野, 所以我行for /f 果阵每行头尾都加左"
所以最尾又要trim返走头尾"
自己都写到乱晒
作者: zone1326 发布时间: 2013-11-13
相关阅读 更多
热门阅读
-
office 2019专业增强版最新2021版激活秘钥/序列号/激活码推荐 附激活工具
阅读:74
-
如何安装mysql8.0
阅读:31
-
Word快速设置标题样式步骤详解
阅读:28
-
20+道必知必会的Vue面试题(附答案解析)
阅读:37
-
HTML如何制作表单
阅读:22
-
百词斩可以改天数吗?当然可以,4个步骤轻松修改天数!
阅读:31
-
ET文件格式和XLS格式文件之间如何转化?
阅读:24
-
react和vue的区别及优缺点是什么
阅读:121
-
支付宝人脸识别如何关闭?
阅读:21
-
腾讯微云怎么修改照片或视频备份路径?
阅读:28