How to include the percent character in the visual studio debugger command line arguments?

China☆狼群 提交于 2019-12-18 14:47:09

问题


I want to debug a program in Visual Studio 2010 SP1 with an argument like: "file-%04d.jpg".

But entering this string in Project Properties > Config Properties > Debugging > Command Arguments changes the "%04", resulting in argv[1] being set to: "file-[some unknown symbol]d.jpg".

The percent character seems to be interpreted as an escape sequence which is not what I want. This does not happen in 2008.


回答1:


%xx seems to be interpreted as an ascii escape. So %25 should result in a real % character in the argument list.



来源:https://stackoverflow.com/questions/7882295/how-to-include-the-percent-character-in-the-visual-studio-debugger-command-line

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!