PdfProducerProduce Method (Stream, ImportFormat, Stream)
Produce the PDF stream using specified import format.
Examples
This sample shows how to produce Pdf stream from CGM stream.
string inputFile = "myImage.cgm";
string outputFile = "myPdf.pdf";
using (FileStream inputStream = File.OpenRead(inputFile))
using (FileStream outputStream = File.Create(outputFile))
{
    PdfProducer.Produce(inputStream, ImportFormat.Cgm, outputStream);
}

Namespace: Aspose.Pdf.Facades
Assembly: Aspose.PDF (in Aspose.PDF.dll) Version: 19.11
Syntax
public static void Produce(
	Stream inputStream,
	ImportFormat format,
	Stream outputStream
)

Parameters

inputStream
Type: System.IOStream
Input stream.
format
Type: Aspose.PdfImportFormat
Import format.
outputStream
Type: System.IOStream
Output PDF stream.
Exceptions
ExceptionCondition
InvalidFileFormatExceptionThe exception is thrown when a file is invalid.
ArgumentNullExceptionInput or output stream is null
See Also