Splitting PDF documents
Splitting PDF documents
Hello,
is there any chance to get particular pages of a loaded pdf document in a memorystream or at least in a file.
The documentation mentions "...PDF creation, PDF edition, split, merge, compress..." and I can't find a functionallity like this.
In our implementation we need to merge single pages of a document and save them in their original state...so searchable pdfs should be preserved.
For this reason the image rasterization process is not suitable.
Do you have any idea how to solve this issue?
Best regards
Tobias Herold
is there any chance to get particular pages of a loaded pdf document in a memorystream or at least in a file.
The documentation mentions "...PDF creation, PDF edition, split, merge, compress..." and I can't find a functionallity like this.
In our implementation we need to merge single pages of a document and save them in their original state...so searchable pdfs should be preserved.
For this reason the image rasterization process is not suitable.
Do you have any idea how to solve this issue?
Best regards
Tobias Herold
Re: Splitting PDF documents
Hi Tobias,
Easy to do. You need to use the clone method. Here a snippet:
let me know if you need more information.
Loïc
Easy to do. You need to use the clone method. Here a snippet:
Code: Select all
Dim src_pdf As New GdPicturePDF
Dim new_pdf As New GdPicturePDF
src_pdf.SetLicenseNumber("XXX")
src_pdf.LoadFromFile("C:\GdPicture.NET8.pdf", False)
new_pdf.NewPDF()
new_pdf.ClonePage(src_pdf, 10)
Dim memory_stream As New IO.MemoryStream
new_pdf.SaveToStream(memory_stream)'save the pdf to stream
new_pdf.SaveToFile("c:\dumppage.pdf") 'save the pdf to file
Loïc
Re: Splitting PDF documents
Great! That's all I need, thank you so much.
Re: Splitting PDF documents
You are welcome,
We will provide a buch of snippets really soon that demonstrate several scenarios of usage.
Kind regards,
Loïc
We will provide a buch of snippets really soon that demonstrate several scenarios of usage.
Kind regards,
Loïc
Re: Splitting PDF documents
Here you can find updated code snippet based on GdPicture.NET 14:
Splitting PDF documents by number of pages
https://www.gdpicture.com/guides/gdpicture/web ... ages.html
Splitting PDF documents by number of pages
https://www.gdpicture.com/guides/gdpicture/web ... ages.html
Who is online
Users browsing this forum: No registered users and 1 guest