使用应用程序在线将 DOT 文件转换为 JSON 文件
- 上传 DOT 文件进行转换
- 等待几秒钟或更长时间,具体取决于 DOT 大小
- 留意上传状态栏
- 点击“转换”按钮
- DOT 将转换为 JSON 文档
- 下载转换后的JSON文件
通过 .NET 自动化 API 将 DOT 转换为 JSON
通过 C# .NET 将 DOT 转换为 JSON
// supports DOC, DOT, DOCX, DOCM, DOTX, DOTM, RTF, WordML, MOBI, ODT, and OTT file formats | |
// load DOCX as input file format with an instance of Document class | |
var document = new Document("template.docx"); | |
// save document in HTML format | |
document.Save("html_output.html", Aspose.Words.SaveFormat.Html); | |
// load the HTML file in an instance of Workbook | |
var book = new Workbook("html_output.html"); | |
// save input document as JSON | |
book.Save("output.json", SaveFormat.Json); |
使用其他功能(如 通过 C# 将受保护的 DOT 转换为 JSON 格式, 通过 C# 将 DOT 转换为 Range 中的 JSON)将 DOT 保存为 JSON 的情况较少。
// supports DOC, DOT, DOCX, DOCM, DOTX, and DOTM file formats | |
// load DOCX as input file format with an instance of Document class | |
var document = new Document("template.docx", new LoadOptions("MyPassword")); | |
// save document in HTML format | |
document.Save("html_output.html", Aspose.Words.SaveFormat.Html); | |
// load the HTML file in an instance of Workbook | |
var book = new Workbook("html_output.html"); | |
// save input document as JSON | |
book.Save("output.json", SaveFormat.Json); |
// supports DOC, DOT, DOCX, DOCM, DOTX, DOTM, RTF, WordML, MOBI, ODT, and OTT file formats | |
// load DOCX as input file format with an instance of Document class | |
var document = new Document("template.docx"); | |
// save document in HTML format | |
document.Save("html_output.html", Aspose.Words.SaveFormat.Html); | |
// load HTML file with an instance of Workbook | |
var workbook = new Cells.Workbook("output.html", new Cells.LoadOptions(Cells.LoadFormat.Auto)); | |
// access CellsCollection of the worksheet containing data to be converted | |
var cells = workbook.Worksheets[0].Cells; | |
// create & set ExportRangeToJsonOptions for advanced options | |
var exportOptions = new Cells.Utility.ExportRangeToJsonOptions(); | |
// create a range of cells containing data to be exported | |
var range = cells.CreateRange(0, 0, cells.LastCell.Row + 1, cells.LastCell.Column + 1); | |
// export range as JSON data | |
string jsonData = Cells.Utility.JsonUtility.ExportRangeToJson(range, exportOptions); | |
// write data file to disc in JSON format | |
System.IO.File.WriteAllText("output.json", jsonData); |
使用 .NET 开发 DOT 文件转换应用程序
需要开发基于 .NET 的软件应用程序来轻松保存和导出 DOT 文件到 JSON 文档吗? 借助
Aspose.Total for .NET
,任何 .NET 开发人员都可以集成上述 API 代码来编写跨多种格式的转换应用程序,包括 Microsoft Word、Excel、Powerpoint、PDF、电子邮件文件、图像和其他格式。 强大的.NET 文档转换库,支持许多流行格式,包括 DOT 格式。 将文档导出为其他格式,程序员可以使用 Aspose.Total 的 .NET 子 API,包括
Aspose.Words for .NET
、
Aspose.Cells for .NET
、
Aspose.Slides for .NET
、
Aspose.PDF for .NET
、
Aspose.Imaging for .NET
等。
DOT .NET 转换库
有三种可选方法可以将 Aspose.Total for .NET 安装到您的系统上。 请选择一个符合您需求的方案并按照分步说明进行操作:
- 安装 NuGet Package 。参见 文档
- 使用包管理器控制台安装库,并在 Visual Studio IDE 中选择其子 API,如 Aspose.Wrods 、 Aspose.Cells 、 Aspose.PDF 等
- 使用 Windows Installer 手动安装库
正在将 DOT 保存至 JSON 应用要求
我们的产品是完全跨平台的,并支持遵循“.NET Standard 2.0”规范的所有主要.NET 实现:
- Microsoft .NET Framework,从最早的2.0版本开始,到最新的“.NET Framework 4.8”结束
- .NET Core,从最早的2.0开始,到最新的‘.NET 6’结束
- Mono >= 2.6.7
由于 .NET 代码不依赖于底层硬件或操作系统,而只依赖于虚拟机,因此您可以自由地为 Windows、macOS、Android、iOS 和 Linux 开发任何类型的软件。 只需确保您已安装相应版本的.NET Framework、.NET Core、Windows Azure、Mono 或 Xamarin。
我们建议使用 Microsoft Visual Studio、Xamarin 和 MonoDevelop IDE 来创建 C#、F#、VB.NET 应用程序。
常见问题解答
- 我可以在我的应用程序中使用上述.NET 代码吗?是的,欢迎您下载此代码。可以轻松开发专业解决方案,使用 .NET 将 DOT 导出并保存到 JSON 文件。 使用 Aspose DOT 到 JSON 转换 API 在 .NET 中开发高级、独立于平台的软件。
- 这个文档导出应用程序只在 Windows 上有效吗?您可以灵活地从任何设备启动将文档从 DOT 导出到 JSON,无论它运行的操作系统是什么,无论是 Windows、Linux、Mac OS 还是 Android。 所需的只是一个现代的网络浏览器和一个有效的互联网连接。
- 使用在线应用程序转换多个 DOT 文档是否安全?当然!通过我们的服务生成的输出文件将在 24 小时内安全自动地从我们的服务器中删除。 因此,在此期间之后,与这些文件相关的下载链接将不再起作用。
- 应该使用什么浏览器来使用App?您可以使用任何现代网络浏览器(如 Google Chrome、Firefox、Opera 或 Safari)进行在线 DOT 文档转换。
- 我如何导出多个 DOT 文件?首先上传一个或多个要转换的文件。您可以拖放 DOT 文件,也可以直接单击白色区域。 然后,单击“转换”按钮,我们的在线转换应用程序将快速处理上传的文件。
- 转换 DOT 文件需要多长时间?该转换应用程序运行迅速,可能需要几秒钟或更长时间,具体取决于文档大小上传并保存为所需格式。