This file contains hidden or 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
import groupdocs.viewer as gv | |
import groupdocs.viewer.options as gvo | |
# Load the source MHTML file and convert it to PDF | |
with gv.Viewer("./input.mhtml") as viewer: | |
# Create a PDF file for the document. | |
# Specify the PDF file name. | |
viewOptions = gvo.PdfViewOptions("./output.pdf") | |
viewer.view(viewOptions) |
This file contains hidden or 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
import groupdocs.viewer as gv | |
import groupdocs.viewer.options as gvo | |
with gv.Viewer("./input.chm") as viewer: | |
# Convert the CHM file to HTML. | |
# {0} is replaced with the page numbers in the output file names. | |
viewOptions = gvo.HtmlViewOptions.for_embedded_resources("./chm_result_{0}.html") | |
# Enable the following option to display all CHM content on a single HTML page. | |
# viewOptions.setRenderToSinglePage(true) | |
viewer.view(viewOptions) |
This file contains hidden or 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
import groupdocs.viewer as gv | |
import groupdocs.viewer.options as gvo | |
# Load the source HTML file | |
with gv.Viewer("./input.html") as viewer: | |
# Create a JPEG image for each drawing page. | |
# {0} is replaced with the current page number in the image name. | |
viewOptions = gvo.JpgViewOptions("output_{0}.jpg") | |
# Set width and height. | |
viewOptions.width = 1600 |
This file contains hidden or 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
import groupdocs.viewer as gv | |
import groupdocs.viewer.options as gvo | |
# Load the source HTML file | |
with gv.Viewer("./input.html") as viewer: | |
# Convert the HTML to PNG | |
# {0} is replaced with the page numbers in the output image names. | |
viewOptions = gvo.PngViewOptions("./output_{0}.png") | |
# Set width and height. | |
viewOptions.width = 950 |
This file contains hidden or 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
import groupdocs.viewer as gv | |
import groupdocs.viewer.options as gvo | |
# Load the source HTML file and convert it to PDF | |
with gv.Viewer("./input.html") as viewer: | |
# Create a PDF file for the document. | |
# Specify the PDF file name. | |
viewOptions = gvo.PdfViewOptions("./output.pdf") | |
viewer.view(viewOptions) |
This file contains hidden or 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
# This code converts a PowerPoint file to HTML format | |
# using GroupDocs.Viewer for Python via .NET. | |
import groupdocs.viewer as gv | |
import groupdocs.viewer.options as gvo | |
# Load the source PPTX file and convert it to HTML | |
with gv.Viewer("./input.pptx") as viewer: | |
# Create an HTML file for each slide. | |
# {0} is replaced with the current page number in the file name. | |
options = gvo.HtmlViewOptions.for_embedded_resources("./page_{0}.html") |
This file contains hidden or 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
# Make sure to install the GroupDocs.Viewer for Python via .NET | |
# and have a valid license. | |
import groupdocs.viewer as gv | |
import groupdocs.viewer.options as gvo | |
# Load the source PPTX file and convert it to JPG images | |
with gv.Viewer("./input.pptx") as viewer: | |
# Create JPG view options | |
viewOptions = gvo.JpgViewOptions("./output_{0}.jpg") | |
# Render the PPTX sheets to JPG images |
This file contains hidden or 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
# Make sure to install the GroupDocs.Viewer for Python via .NET | |
# and have a valid license. | |
import groupdocs.viewer as gv | |
import groupdocs.viewer.options as gvo | |
# Load the source PPTX file and convert it to PNG images | |
with gv.Viewer("./input.pptx") as viewer: | |
# Create PNG view options | |
viewOptions = gvo.PngViewOptions("./output_{0}.png") | |
# Render the PPTX sheets to PNG images |
This file contains hidden or 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
# This code converts a PowerPoint file to PDF | |
# using GroupDocs.Viewer for Python via .NET. | |
import groupdocs.viewer as gv | |
import groupdocs.viewer.options as gvo | |
# Load the source PPTX file and convert it to PDF | |
with gv.Viewer("./input.pptx") as viewer: | |
viewOptions = gvo.PdfViewOptions("./output.pdf") | |
viewer.view(viewOptions) |
NewerOlder