|
|
Rank: Member Groups: Member
Joined: 10/6/2016 Posts: 10
|
Hi Support Team,
we are using EO.WebBrowser (version 25.1.35.0) in our application. Within our web application, PDFs are rendered using embedpdf for React and displayed correctly. However, when users attempt to print these PDFs, the operation fails due to a Content Security Policy (CSP) violation, which appears to be blocked by the embedded browser.
Could you please advise whether this is a known limitation or configuration issue in EO.WebBrowser? Additionally, are there recommended settings or workarounds to allow PDF printing in this scenario? Thank you in advance for your support. Kind regards, Virgile
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,488
|
Hi, How do you print the PDF file? We tested build 25.1.35 with the following steps and it appears to work: 1. Run TabbedBrowser sample application; 2. Load embedpdf demo page: https://app.embedpdf.com/3. Click the "=" button for the PDF Viewer, then select "Print"; This successfully sends the PDF to the printer. So your steps must be different. Please let us know the details of your steps so we can test here again. Thanks!
|
|
Rank: Member Groups: Member
Joined: 10/6/2016 Posts: 10
|
Hello Team,
Our steps are the same. But we found out that when the setting Download PDFs is activated in Chrome then we receive the following error : Uncaught SecurityError: Failed to read a named property 'print' from 'Window': Blocked a frame with origin "https://app.embedpdf.com" from accessing a cross-origin frame. It works properly in the Chrome Web Version if we activate the other setting - Open PDFs in Chrome. In our EO Browser we receive always the error mentioned above. Is there a way to change the corresponding / equivalent setting for EO browser?
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,488
|
Hi,
EO.WebBrowser does not have the settings equivalent to Chrome's Download PDF/Open PDF.
You keep saying "in our EO Browser we always receive the error". However we tested with TabbedBrowser and it worked fine. So maybe there is something different between how your code uses EO.WebBrowser and how TabbedBrowser sample uses it?
Thanks!
|
|
Rank: Member Groups: Member
Joined: 10/6/2016 Posts: 10
|
Thank you for your response. I will try to describe what we are doing in more detail.
The DLL dependencies used in our project are: EO.Base.dll EO.WebBrowser.dll EO.WebBrowser.Wpf.dll EO.WebEngine.dll EO.Wpf.dll eowp.exe
Our WPF application contains your WebView in its view model, which loads the URL of our React web application. After a user action, a PDF generated by the backend is displayed using embedPDF. The PDF is accessed via a blob URL. When the user tries to print this PDF, the CSP violation described previously occurs. Is this description clear and comprehensive enough, or do you need more details? I noticed that I cannot attach screenshots in this forum. This would make it easier to explain the issue. Is there a way to share screenshots?
Thank you in advance for your help.
|
|