What does char 160 mean in my source code?

前端 未结 8 1070
温柔的废话
温柔的废话 2021-02-05 00:01

I am formatting numbers to string using the following format string \"# #.##\", at some point I need to turn back these number strings like (1 234 567) into something like 1234

8条回答
  •  无人共我
    2021-02-05 00:20

    Maybe you could to use a regex to replace those empty chars:

    Regex.Replace(input, @"\p{Z}", "");
    

    This will remove "any kind of whitespace or invisible separator".

提交回复
热议问题