Convert OTG files
Contents
[
Hide
]
Convert OTG files
Aspose.Imaging for .NET now supports converting images from OTG to PDF and other image formats. Following code snippet demonstrates the said functionality.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Aspose.Imaging; | |
using Aspose.Imaging.FileFormats.OpenDocument; | |
using Aspose.Imaging.ImageOptions; | |
using System.IO; | |
string templatesFolder = @"c:\Users\USER\Downloads\templates\"; | |
string dataDir = templatesFolder; | |
using (OtgImage image = (OtgImage)Image.Load(dataDir + "template.otg")) | |
{ | |
image.Save(dataDir + "result.pdf", new PdfOptions()); | |
} | |
File.Delete(dataDir + "result.pdf"); |