AddFromPdf()
Contents
[
Hide
]ISlideCollection::AddFromPdf(System::String) method
Creates slides from the PDF document and adds them to the end of the collection.
virtual System::ArrayPtr<System::SharedPtr<ISlide>> Aspose::Slides::ISlideCollection::AddFromPdf(System::String path)=0
Arguments
Parameter | Type | Description |
---|---|---|
path | System::String | A path to the PDF document |
Return Value
Added slides
Remarks
Example:
auto pres = MakeObject<Presentation>();
pres->get_Slides()->AddFromPdf(u"document.pdf");
pres->Save(u"fromPdfDocument.pptx", SaveFormat::Pptx);
ISlideCollection::AddFromPdf(System::String, System::SharedPtr<Import::PdfImportOptions>) method
Creates slides from the PDF document and adds them to the end of the collection considering the pdf import options.
virtual System::ArrayPtr<System::SharedPtr<ISlide>> Aspose::Slides::ISlideCollection::AddFromPdf(System::String path, System::SharedPtr<Import::PdfImportOptions> pdfImportOptions)=0
Arguments
Parameter | Type | Description |
---|---|---|
path | System::String | A path to the PDF document |
pdfImportOptions | System::SharedPtr<Import::PdfImportOptions> | Options for pdf import |
Return Value
Added slides
Remarks
Example:
System::SharedPtr<Presentation> pres = System::MakeObject<Presentation>();
System::SharedPtr<PdfImportOptions> options = System::MakeObject<PdfImportOptions>();
options->set_DetectTables(true);
pres->get_Slides()->AddFromPdf(u"document.pdf", options);
pres->Save(u"fromPdfDocument.pptx", SaveFormat::Pptx);
ISlideCollection::AddFromPdf(System::SharedPtr<System::IO::Stream>, System::SharedPtr<Import::PdfImportOptions>) method
Creates slides from the PDF document and adds them to the end of the collection.
virtual System::ArrayPtr<System::SharedPtr<ISlide>> Aspose::Slides::ISlideCollection::AddFromPdf(System::SharedPtr<System::IO::Stream> pdfStream, System::SharedPtr<Import::PdfImportOptions> pdfImportOptions)=0
Arguments
Parameter | Type | Description |
---|---|---|
pdfStream | System::SharedPtr<System::IO::Stream> | A stream which will be used as a source of the PDF document |
pdfImportOptions | System::SharedPtr<Import::PdfImportOptions> | Options for pdf import |
Return Value
Added slides
Remarks
Example:
System::SharedPtr<Presentation> pres = System::MakeObject<Presentation>();
System::SharedPtr<Stream> stream = System::MakeObject<FileStream>(u"document.pdf", System::IO::FileMode::Open, System::IO::FileAccess::Read, System::IO::FileShare::Read);
System::SharedPtr<PdfImportOptions> options = System::MakeObject<PdfImportOptions>();
options->set_DetectTables(true);
// set detecting tables
pres->get_Slides()->AddFromPdf(stream, options);
pres->Save(u"fromPdfDocument.pptx", SaveFormat::Pptx);
ISlideCollection::AddFromPdf(System::SharedPtr<System::IO::Stream>) method
Creates slides from the PDF document and adds them to the end of the collection.
virtual System::ArrayPtr<System::SharedPtr<ISlide>> Aspose::Slides::ISlideCollection::AddFromPdf(System::SharedPtr<System::IO::Stream> pdfStream)=0
Arguments
Parameter | Type | Description |
---|---|---|
pdfStream | System::SharedPtr<System::IO::Stream> | A stream which will be used as a source of the PDF document |
Return Value
Added slides
Remarks
Example:
auto pres = MakeObject<Presentation>();
auto stream = MakeObject<IO::FileStream>(u"document.pdf", IO::FileMode::Open, IO::FileAccess::Read, IO::FileShare::Read);
pres->get_Slides()->AddFromPdf(stream);
pres->Save(u"fromPdfDocument.pptx", SaveFormat::Pptx);
See Also
- Typedef ArrayPtr
- Typedef SharedPtr
- Class ISlide
- Class String
- Class ISlideCollection
- Class PdfImportOptions
- Class Stream
- Namespace Aspose::Slides
- Library Aspose.Slides