เข้าถึงการนำเสนอ OpenDocument
Contents
[
Hide
]
Aspose.Slides for .NET มีคลาส Presentation ที่ใช้แทนไฟล์งานนำเสนอ. คลาส Presentation ตอนนี้สามารถเข้าถึง ODP ผ่านคอนสตรัคเตอร์ Presentation เมื่อวัตถุถูกสร้างขึ้น.
ตัวอย่าง
string FilePath = @"..\..\..\Sample Files\";
string srcFileName = FilePath + "OpenDocument Presentation.odp";
string destFileName = FilePath + "OpenDocument Presentation.pptx";
//สร้างอ็อบเจ็กต์ Presentation ที่เป็นตัวแทนของไฟล์งานนำเสนอ
using (Presentation pres = new Presentation(srcFileName))
{
//บันทึกงานนำเสนอ PPTX เป็นรูปแบบ PPTX
pres.Save(destFileName, SaveFormat.Pptx);
}