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

โปรแกรมดูไฟล์ ODP สำหรับ .NET

ดูไฟล์การนำเสนอ เช่น ODP โดยไม่ต้องใช้ Microsoft PowerPoint หรือ Office Automation

วิธีดูไฟล์ ODP โดยใช้ C#

ในการดูไฟล์ ODP เราจะใช้

Aspose.Slides สำหรับ .NET

API ซึ่งเป็น API ที่มีคุณลักษณะหลากหลาย มีประสิทธิภาพ และใช้งานง่ายสำหรับแพลตฟอร์ม C# ที่จะใช้กับโปรแกรมดูใดก็ได้ เปิด

NuGet

package manager ค้นหา สมมติ.สไลด์ และติดตั้ง คุณยังสามารถใช้คำสั่งต่อไปนี้จาก Package Manager Console

คำสั่งคอนโซลตัวจัดการแพ็คเกจ


PM> Install-Package Aspose.Slides.NET

ขั้นตอนในการดู ODP ผ่าน C#

Aspose.Slides ช่วยให้นักพัฒนาสามารถดูไฟล์ ODP ได้ง่ายด้วยโค้ดเพียงไม่กี่บรรทัด

  1. สร้างอินสแตนซ์วัตถุการนำเสนอและโหลดไฟล์ ODP

  2. สร้างอินสแตนซ์ ResponsiveHtmlController สำหรับการจัดรูปแบบ

  3. สร้างอินสแตนซ์ของ HtmlOptions และตั้งค่าคุณสมบัติ HtmlFormatter

  4. บันทึกงานนำเสนอ ODP ในรูปแบบ HTML

  5. กระบวนการเรียก เริ่มต้นด้วยเส้นทางไปยัง HTML ที่เป็นผลลัพธ์เพื่อโหลดเนื้อหา ODP ในเบราว์เซอร์เริ่มต้น

ความต้องการของระบบ

Aspose.Slides สำหรับ .NET รองรับระบบปฏิบัติการหลักทั้งหมด เพียงตรวจสอบให้แน่ใจว่าคุณมีข้อกำหนดเบื้องต้นดังต่อไปนี้

  • Microsoft Windows หรือระบบปฏิบัติการที่เข้ากันได้กับ .NET Framework, .NET Core, Windows Azure, Mono หรือ Xamarin Platforms
  • สภาพแวดล้อมการพัฒนาเช่น Microsoft Visual Studio
  • Aspose.Slides สำหรับ .NET ที่อ้างอิงในโครงการของคุณ
 

โค้ดตัวอย่าง C# เพื่อดูไฟล์ ODP


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

// instantiate a Presentation object & load the ODP file
using (var presentation = new Aspose.Slides.Presentation("templateodp"))
{
    // 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 สำหรับ .NET API

    Aspose.Slides API สามารถใช้อ่าน เขียน จัดการ และแปลงเอกสาร Microsoft PowerPoint เป็น PDF, XPS, HTML, TIFF, ODP และรูปแบบอื่นๆ ได้ หนึ่งสามารถสร้างไฟล์ใหม่ตั้งแต่เริ่มต้นและบันทึกในรูปแบบที่รองรับที่เกี่ยวข้อง Aspose.Slides เป็น API แบบสแตนด์อโลนสำหรับการสร้าง แยกวิเคราะห์ หรือจัดการการนำเสนอ สไลด์ และองค์ประกอบ และไม่ขึ้นกับซอฟต์แวร์ใดๆ เช่น Microsoft หรือ OpenOffice

    Free App to View ODP

    Check our live demos to View ODP with following benefits.

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

    ODP ODP รูปแบบไฟล์คืออะไร

    Files with ODP extension represent presentation file format used by OpenOffice.org in the OASISOpen standard. A presentation file is a collection of slides where each slide can comprise of text, images, formatting, animations, and other media. These slides are presented to audience in the form of slideshows with custom presentation settings. ODP files can be opened by applications that conform to the OpenDocument format (such as OpenOffice or StarOffice).

    อ่านเพิ่มเติม

    รูปแบบตัวแสดงที่รองรับอื่น ๆ

    การใช้ C# สามารถดูรูปแบบไฟล์อื่น ๆ ได้มากมายรวมทั้ง

    OTP (รูปแบบมาตรฐานของ OpenDocument)
    POT (ไฟล์เทมเพลต Microsoft PowerPoint)
    POTM (ไฟล์เทมเพลต Microsoft PowerPoint)
    POTX (การนำเสนอเทมเพลต Microsoft PowerPoint)
    PPS (สไลด์โชว์ PowerPoint)
    PPSM (สไลด์โชว์ที่เปิดใช้งานมาโคร)
    PPSX (สไลด์โชว์ PowerPoint)
    PPT (Microsoft PowerPoint 97-2003)
    PPTM (ไฟล์นำเสนอที่เปิดใช้งานมาโคร)
    PPTX (เปิดรูปแบบการนำเสนอ XML)