I am able to view PDF using the "view-sdk" or embedded pdf viewer library (not sure of the name). However when I try to load a password protected PDF, it displays nothing on the page and does not prompt for password. Is there a way to view password protected PDF's using the embedded api?
Copy link to clipboard
Embed API supports viewing password-protected PDF and you should see an on-screen prompt to enter the password. See image below. Also, please share your code and the PDF in question so we can further diagnose the issue.
I figured out that it was because we were hiding the pdf div until APP_RENDERING_DONE event was fired. We were doing that technique in order to prevent the layered rendering effect that we were seeing.
Do you know of a way to modify this code pen to work with password protected files too? https://community.adobe.com/t5/document-services-apis/how-to-preload-pdf-to-avoid-layered-rendering-...
Yeah - Without the password, rendering will never even start. Unfortunately, there is no way to pass a password to Embed API. You won't be able to prevent the layered rendering but you can probably throw a <div> over it to prevent mouse clicks until rendering is done.