Dapatkan Format File Presentasi
Contents
[
Hide
]
Untuk mendapatkan format file, ikuti langkah‑langkah berikut:
- Buat instance dari kelas IPresentationInfo
- Dapatkan informasi tentang presentasi
Pada contoh di bawah ini, kami memperoleh format file.
Contoh
string FilePath = @"..\..\..\Sample Files\";
string FileName = FilePath + "Getting the format of a file.pptx";
IPresentationInfo info;
info = PresentationFactory.Instance.GetPresentationInfo(FileName);
switch (info.LoadFormat)
{
case LoadFormat.Pptx:
{
break;
}
case LoadFormat.Unknown:
{
break;
}
}