Please enable JavaScript to view this site.

Navigation: Developer Information > Command Line Interface

Command Line Convert To Format

Scroll Prev Top Next More

Convert To Format Command Line

 

win2pdfd.exe convertto "sourcefile" "destfile" destformat

 

Converts the sourcefile to the specified format, and saves the converted file to destfile. The "sourcefile" parameter can be one of the following formats:

 

Extension

Format

.PDF

Portable Document Format

.HTML, .HTM, .MHTML, .JS

HyperText Markup Language

.SVG

Scalable Vector Graphics

.XPS

XML Paper Specification

.TIF, .TIFF

Tagged Image File Format

.JPG, .JPEG, .JPE

Joint Photographic Experts Group Image

.PNG

Portable Network Graphics

.BMP, .DIB

Windows Bitmap

.GIF

Graphics Interchange Format

 

Files not matching one of these extensions cannot be converted with this command.

 

The "destformat" can be one of the following:

 

destformat parameter

Description

pdf

Portable Document Format

pdfimagemono

PDF Image Only - monochrome

pdfimagegrayscale

PDF Image Only - grayscale

pdfimagecolor

PDF Image Only - color

pdfcompressed

PDF - compressed

pdfsearchable

PDF - searchable (OCR)

textformatted

Text - formatted

textunformatted

Text - unformatted

jpggray

JPG - grayscale

jpg

JPG - color

tiffmono

TIFF - monochrome

tiffgray

TIFF - grayscale

tiff

TIFF - color

tifftransparent

TIFF - color with transparent background

pnggray

PNG - Grayscale

png

PNG - Color

pnggraytransparent

PNG - Grayscale with transparent background

pngtransparent

PNG - Color with transparent background

ocrtextformatted

Text - formatted after making searchable, requires optional Win2PDF Desktop Searchable component

ocrtextunformatted

Text - unformatted after making searchable, formatted after making searchable, requires optional Win2PDF Desktop Searchable component

 

Any file names that contain spaces must be enclosed with quotation marks. The "sourcefile" can be a local file path, or an web address (URL) to an existing PDF.

 

For specific examples of using the convertto command to convert from one format to another, see:

Command Line Convert HTML to Text

Command Line Convert HTML to JPG

Command Line Convert HTML to TIFF

Command Line Convert HTML to PNG

Command Line Convert XPS to Text

Command Line Convert XPS to JPG

Command Line Convert XPS to TIFF

Command Line Convert XPS to PNG

Command Line Convert TIFF to Text

Command Line Convert TIFF to JPG

Command Line Convert TIFF to TIFF

Command Line Convert TIFF to PNG

Command Line Convert JPG to Text

Command Line Convert JPG to JPG

Command Line Convert JPG to TIFF

Command Line Convert JPG to PNG

Command Line Convert PNG to Text

Command Line Convert PNG to JPG

Command Line Convert PNG to TIFF

Command Line Convert PNG to PNG

Command Line Convert BMP to Text

Command Line Convert BMP to JPG

Command Line Convert BMP to TIFF

Command Line Convert BMP to PNG

Command Line Convert GIF to Text

Command Line Convert GIF to JPG

Command Line Convert GIF to TIFF

Command Line Convert GIF to PNG

 

 

 

This feature requires a licensed version of Win2PDF. Contact us for a time limited evaluation license.

 

Returns 0 on success, and a Windows system error code on failure.