-
Notifications
You must be signed in to change notification settings - Fork 150
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Suggestion: PdfDocumentRenderer.RenderDocument() should support cancel/stop #19
Comments
It is possible to render documents page by page. If you do it this way, you can stop or cancel as well. |
Thanks, I will have a try. |
Hi @TH-Soft , I tried your suggestion, yes I can render documents page by page, but before that, the call to |
There is a callback that allows you to display the progress of the preparation. I don't know how to stop the preparation from within the callback. Not sure if throwing an exception is enough to stop preparation. Link to sample code in the support forum (shows progress, but does not yet support cancellation): |
Yes, wrap a thread is my current workaround, but it is better to add a method or parameter to make it cancelable, because thread.abort is not recommend as it's unsafe, and recent .net core even drop support for it. My proposal is, add a new method |
I tested it: an exception thrown in If you want to use a |
it works. thank you. |
Hi,
Because when creating a large PDF, the
PdfDocumentRenderer.RenderDocument()
may take several minutes to execute, it's better to add a API to allow cancelling/stopping it.The text was updated successfully, but these errors were encountered: