码迷,mamicode.com
首页 > 其他好文 > 详细

如何设置文本文件的默认保存编码为UTF-8

时间:2016-04-29 22:10:49      阅读:210      评论:0      收藏:0      [点我收藏+]

标签:

原文:http://answers.microsoft.com/en-us/windows/forum/windows_7-windows_programs/default-utf-8-encoding-for-new-notepad-documents/525f0ae7-121e-4eac-a6c2-cfe6b498712c?auth=1

 

1. Right click -> New -> Text Document
2. Open "New Text Document.txt". Do NOT type anything!
3. Go to "File -> Save As... " and choose UTF-8 under "Encoding:", press "Save" and overwrite existing file. Close the file.
4. Rename "New Text Document.txt" to "TXTUTF-8.txt"
5. Copy "TXTUTF-8.txt" to "C:\WINDOWS\SHELLNEW"
6. Go to "Start -> Run..." and type
---------
regedit
---------
Press OK.
7. Navigate to
-------------------------------------------
HKEY_CLASSES_ROOT\.txt\ShellNew
-------------------------------------------
8. Right click in the right window -> New -> "String Value" and rename it to
-----------
FileName
-----------
9. Double click on "FileName" and put
----------------
TXTUTF-8.txt
----------------
into "Value data:" field and press OK.
10. It‘s finished.
11. Test it: Create new .txt document (Right click -> New -> Text Document). Open it and go to "File -> Save As... " and see that encoding is set by default to UTF-8 . :-)

如何设置文本文件的默认保存编码为UTF-8

标签:

原文地址:http://www.cnblogs.com/chenxizhang/p/5447538.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!