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
// Load the source DOCX file | |
com.groupdocs.conversion.Converter converter = new com.groupdocs.conversion.Converter("sample.docx"); | |
// Create an object of PresentationConvertOptions class | |
com.groupdocs.conversion.options.convert.PresentationConvertOptions options = new com.groupdocs.conversion.options.convert.PresentationConvertOptions(); | |
// Convert Word DOCX to PPTX Presentation | |
converter.convert("Presentation.pptx", options); |
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
// Initialize an HTML document from the file | |
var document = new com.aspose.html.HTMLDocument("spring.html"); | |
// Initialize PdfSaveOptions | |
var options = new com.aspose.html.saving.PdfSaveOptions(); | |
// Convert HTML to PDF | |
com.aspose.html.converters.Converter.convertHTML(document, options, "spring-output.pdf"); | |
// Load PDF document |
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
// Instantiate Document object | |
Document doc = new Document(); | |
// Bind source XML file | |
doc.BindXml(dataDir + "input.xml"); | |
// Convert XML to PDF | |
doc.Save(dataDir + "XMLToPDF.pdf"); |
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
// Load PDF document | |
Document document = new Document("input.pdf"); | |
// Convert PDF to XML format | |
document.Save("output.xml", Aspose.Pdf.SaveFormat.MobiXml); |
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
// Load the input Word document | |
Aspose.Words.Document doc = new Aspose.Words.Document("Words.docx"); | |
// Initialize an object of ImageSaveOptions class | |
Aspose.Words.Saving.ImageSaveOptions options = new Aspose.Words.Saving.ImageSaveOptions(Aspose.Words.SaveFormat.Jpeg); | |
// Set the "PageSet" to "0" to convert only the first page of a document. | |
options.PageSet = new Aspose.Words.Saving.PageSet(0); | |
// Set the image's brightness and contrast. |
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
// Create Archive class object | |
var arch = new Archive(); | |
// Specify file names and create entry | |
arch.CreateEntry(dataDir + "input.csv", dataDir + "Sample.csv"); | |
// Save compressed ZIP archive containing CSV data | |
arch.Save(dataDir + "csv_archive.zip"); |
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
// Parse RGB color | |
Aspose.Svg.Drawing.Color rgb = Aspose.Svg.Drawing.Color.FromRgb(150, 121, 199); | |
// Convert RGB to CMYK | |
var cmyk = rgb.Convert(Aspose.Svg.Drawing.ColorModel.Cmyk); | |
// Print the CMYK color | |
Console.WriteLine("CMYK: " + cmyk.ToString()); |
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
// Load input DWG drawing | |
com.aspose.cad.Image image = com.aspose.cad.Image.load("sample.dwg"); | |
// Create an instance of PdfOptions | |
com.aspose.cad.imageoptions.PdfOptions pdfOptions = new com.aspose.cad.imageoptions.PdfOptions(); | |
// Create an instance of CadRasterizationOptions and set its various properties | |
com.aspose.cad.imageoptions.CadRasterizationOptions rasterizationOptions = new com.aspose.cad.imageoptions.CadRasterizationOptions(); |
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
// Initialize an HTML document from the file | |
using var document = new Aspose.Html.HTMLDocument("spring.html"); | |
// Initialize ImageSaveOptions | |
var options = new Aspose.Html.Saving.ImageSaveOptions(Aspose.Html.Rendering.Image.ImageFormat.Jpeg); | |
// Convert HTML to JPG | |
Aspose.Html.Converters.Converter.ConvertHTML(document, options, "spring-output.jpg"); |
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
// Instantiate viewer | |
using (Viewer viewer = new Viewer("resume.docx")) | |
{ | |
// Set output HTML options | |
HtmlViewOptions options = HtmlViewOptions.ForEmbeddedResources(); | |
// Render DOCX to HTML with embedded resources | |
viewer.View(options); | |
} |