Class ImageConverter
Converter for converting template file to pdf.
public class ImageConverter
Inheritance
Inherited Members
- object.GetType(),
- object.MemberwiseClone(),
- object.ToString(),
- object.Equals(object?),
- object.Equals(object?, object?),
- object.ReferenceEquals(object?, object?),
- object.GetHashCode()
Examples
[C#]
LoadOptions loadOptions = new LoadOptions();
loadOptions.InputFile = "Template.xlsx";
ImageSaveOptions saveOptions = new ImageSaveOptions();
ImageConverter.Process(loadOptions, saveOptions);
Methods
Process(LoadOptions, ImageSaveOptions)
Converts template file to images
public static void Process(LoadOptions loadOptions, ImageSaveOptions saveOptions)
Parameters
loadOptions
LoadOptions: Options for input and loading:saveOptions
ImageSaveOptions: Options for output and saving
Remarks
When converting to image of format that supports multiple pages(such as tiff),
the specified Sheetize.SaveOptions.OutputFile
or Sheetize.SaveOptions.OutputStream will be used directly for the resultant image.
For other types of image, if the save options has specified Stream as output,
then all resultant images will be saved to the same Stream.
Otherwise, the output files will be build from the specified output file
of the save options by appending sequence number of the sheet and split part.
For example, if the specified output file is Image.png, then the generated image
files will be Image_0_0.png, Image_0_1.png, …, Image_1_0.png, …
Process(LoadOptions, ImageSaveOptions, AbstractSaveOptionsProvider)
Converts template file to images
public static void Process(LoadOptions loadOptions, ImageSaveOptions saveOptions, AbstractSaveOptionsProvider provider)
Parameters
loadOptions
LoadOptions: Options for input and loading:saveOptions
ImageSaveOptions: Options for saving. Its output(Sheetize.SaveOptions.OutputFile or Sheetize.SaveOptions.OutputStream): takes no effect because all outputs will be specified by the “provider” parameter:provider
AbstractSaveOptionsProvider: Provider of save options for saving the generated images
Namespace: Sheetize Assembly: Sheetize.dll