VS2010 error The file contains a character can not be represented in the current code page (936) in. Please save the file as Unicode format to prevent data loss

In particular, the code is copied from the linux platform:

Error Figure:

 

What is more basic functions are being given:

 

When the next inspection found no problem with basic functions such as if else break case, given the number of apparent inconsistencies and other lines must pay attention to the document encoding format,

The easiest way is to use notepad ++, one by one .cpp and .h into Unicode, as

 

Into UTF-8-BOM encoding, save point.

vs reminded to change the whole point yes.

 

Then generate compile, you will find the original error all but disappeared

Note again QtCreate above happens when the project import vs + qt.

Transfer: https: //blog.csdn.net/yanchenyu365/article/details/84065719

Guess you like

Origin www.cnblogs.com/liushui-sky/p/10977765.html