Viewer does not load correctly - SmartPlant Foundation - IM Update 46 - Help - Hexagon

SmartPlant Foundation Web Client Help

Language
English
Product
SmartPlant Foundation
Search by Category
Help
SmartPlant Foundation / SDx Version
10

Error

When trying to view a file, the viewer is grayed out and the following error appears:

Failed to find PDF worker files. This project is not set up to work with PDF files.

The following error messages appear in the console:

  • Uncaught DOMException: Failed to execute 'importScripts' on 'WorkerGlobalScope': The script at 'blob:https://[webclient]/[objectObid]' failed to load.

  • Refused to load the script 'blob:https://[webclient]/[objectObid]' because it violates the following Content Security Policy directive: "default-src https: data: 'unsafe-inline' 'unsafe-eval'". Note that 'script-src-elem' was not explicitly set, so 'default-src' is used as a fallback.

  • Failed to find PDF worker files. This project is not set up to work with PDF files.

Cause

You might encounter this problem if additional HTTP headers are present, specifically the Content Security Policy header.

Solution

  1. Log on to the application server.

  2. Start the Internet Information Services (IIS) Manager.

  3. Click Default Web Site > HTTP Response Headers.

  4. Select Content Security Policy and click Edit.

  5. Enter default-src https: data: 'unsafe-inline' 'unsafe-eval' script-src: 'self' blob:; for the Value.

  6. Any end-users using the client when these changes are made should refresh their browser.