HTML JPG PDF XML POT
Aspose.Slides  for .NET
POT

.NET 的 POT 文件查看器

在没有 Microsoft PowerPoint 或 Office Automation 的情况下查看 POT 等演示文件

如何使用 C# 查看 POT 文件

为了查看 POT 文件,我们将使用

Aspose.Slides for .NET

API 是一个功能丰富、功能强大且易于使用的 C# 平台 API,可与任何查看器一起使用。打开

NuGet

包管理器,搜索 Aspose.Slides 并安装。您还可以从包管理器控制台使用以下命令。

包管理器控制台命令


PM> Install-Package Aspose.Slides.NET

通过 C# 查看 POT 的步骤

Aspose.Slides 使开发人员只需几行代码即可轻松查看 POT 文件。

  1. 实例化一个 Presentation 对象并加载 POT 文件

  2. 创建一个用于格式化的 ResponsiveHtmlController 实例

  3. 创建 HtmlOptions 的实例并设置 HtmlFormatter 属性

  4. 以 HTML 格式保存 POT 演示文稿

  5. 调用 Process.Start 以生成 HTML 的路径以在默认浏览器中加载 POT 内容

系统要求

所有主要操作系统都支持 Aspose.Slides for .NET。只需确保您具有以下先决条件。

  • Microsoft Windows 或兼容 .NET Framework、.NET Core、Windows Azure、Mono 或 Xamarin 平台的操作系统
  • Microsoft Visual Studio 等开发环境
  • 项目中引用的用于 .NET 的 Aspose.Slides
 

C# 示例代码查看 POT 文件


string output = System.IO.Path.GetTempPath() + Guid.NewGuid().ToString() + ".html";

// instantiate a Presentation object & load the POT file
using (var presentation = new Aspose.Slides.Presentation("templatepot"))
{
    // create HTML export controller
    var controller = new Aspose.Slides.Export.ResponsiveHtmlController();
    // create an instance of HtmlOptions and set HtmlFormatter property
    var htmlOptions = new Aspose.Slides.Export.HtmlOptions 
    { 
        HtmlFormatter = Aspose.Slides.Export.HtmlFormatter.CreateCustomFormatter(controller) 
    };

    // save the presentation in HTML
    presentation.Save(output, Aspose.Slides.Export.SaveFormat.Html, htmlOptions);
}
// load HTML to view the presentation content
System.Diagnostics.Process.Start(output);
 
  • 关于 Aspose.Slides for .NET API

    Aspose.Slides API 可用于读取、编写、操作 Microsoft PowerPoint 文档并将其转换为 PDF、XPS、HTML、TIFF、ODP 和各种其他格式。可以从头开始创建新文件并将其保存为相关支持的格式。 Aspose.Slides 是一个独立的 API,用于创建、解析或操作演示文稿、幻灯片和元素,它不依赖于 Microsoft 或 OpenOffice 等任何软件。

    Free App to View POT

    Check our live demos to View POT with following benefits.

      No need to download or setup anything
      No need to write or compile code
      Just upload POT file and hit the "View" button
      Download POT file from the link, if required

    POT 什么是POT文件格式

    Files with .POT extension represent Microsoft PowerPoint template files created by PowerPoint 97-2003 versions. Files created with these versions of Microsoft PowerPoint are in binary format as compared to those created in Office OpenXML file formats using the higher versions of PowerPoint. The files, hence, generated can be used to create presentations that have same layout and other settings required to be applied to new files. These settings can include styles, backgrounds, colour palette, fonts and defaults. Such files are generated in order to create ready-to-use template files for official use.

    阅读更多

    其他支持的查看器格式

    使用 C#,还可以查看许多其他文件格式,包括。

    ODP (OpenDocument 演示格式)
    OTP (OpenDocument 标准格式)
    POTM (微软 PowerPoint 模板文件)
    POTX (Microsoft PowerPoint 模板演示文稿)
    PPS (幻灯片放映)
    PPSM (启用宏的幻灯片放映)
    PPSX (幻灯片放映)
    PPT (微软PowerPoint 97-2003)
    PPTM (启用宏的演示文件)
    PPTX (打开 XML 表示格式)