使用 Notepad++ 以 json 格式保存文件
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/29232728/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Save a file in json format using Notepad++
提问by Bil Bal
I have a json format (let's say text) in Notepad++.
我在 Notepad++ 中有一个 json 格式(比如说文本)。
I want to save it as a jsonfile using filename.json format.
我想json使用 filename.json 格式将其保存为文件。
How can I make it in Notepad++(because I can't find the extension when I go to save as option)
我怎样才能让它进来Notepad++(因为我在去另存为选项时找不到扩展名)
回答by yiabiten
You can save it as .txt and change it manually using a mouse click and your keyboard. OR, when saving the file:
您可以将其另存为 .txt 并使用鼠标单击和键盘手动更改它。或者,在保存文件时:
- choose
All types(*.*)in theSave as typefield. - type filename.json in
File namefield
All types(*.*)在Save as type字段中选择。- 在
File name字段中输入 filename.json
回答by nom
Save the file as *.txtand then rename the file and change the file extension to json
将文件另存为*.txt,然后重命名文件并将文件扩展名更改为json
回答by Sam
In Notepad++ on the Language menu you will find the menu item - 'J' and under this menu item chose the language - JSON.
在 Notepad++ 的语言菜单中,您会找到菜单项 - 'J',在此菜单项下选择语言 - JSON。
Once you select the JSON language then you won't have to worry about how to save it. When you save it it will by default save it as .JSON file, you have to just select the location of the file.
一旦您选择了 JSON 语言,您就不必担心如何保存它。当您保存它时,它默认将其保存为 .JSON 文件,您只需选择文件的位置。
Thanks, -Sam
谢谢,-山姆
回答by kamikater
回答by Mohamed Shaaban
Just show file name extension from Windows Explorer, after applying the below steps, create a new file, and type your extension as .json
只需从 Windows 资源管理器中显示文件扩展名,在应用以下步骤后,创建一个新文件,然后键入您的扩展名 .json
Open Folder Options by clicking the Start button Picture of the Start button, clicking Control Panel, clicking Appearance and Personalization, and then clicking Folder Options.
通过依次单击“开始”按钮“开始”按钮图片、“控制面板”、“外观和个性化”,然后单击“文件夹选项”,打开文件夹选项。
Click the View tab, and then, under Advanced settings, clear the Hide extensions for known file types check box, and then click OK
单击“查看”选项卡,然后在“高级设置”下清除“隐藏已知文件类型的扩展名”复选框,然后单击“确定”
回答by Bharti Rawat
Simply you can save with extension .jsonbut while saving you have to do some changes.
简单地您可以使用扩展名.json进行保存,但在保存时您必须进行一些更改。
Change Save as typein red circle in image to All Files.
将图像中红色圆圈中的Save as type更改为All Files。
It will create .json file with name bharti.json.
它将创建名为bharti.json 的 .json文件。
To check this --> Right click at file--> Properties--> Type of file: JSON File (.json)
要检查这个 -->右键单击文件-->属性-->文件类型:JSON 文件 (.json)
回答by Nicollas
You can do using a simple notepad and save as FILENAME.json
您可以使用简单的记事本并另存为 FILENAME.json
That's all.
就这样。

