Showing "Error while loading document" in interface when using Appian Webviewer

Product: Apryse WebViewer Component Plug-in

Product Version: 5.5.1

Please give a brief summary of your issue:

I am using webviewer in Appian. I am passing 2 appian doc id as parameters. But as soon as the interface is loaded it shows " Error while loading document ". But when I am manually uploading the two doc it works fine.

Please describe your issue and provide steps to reproduce it:

When using webviewer object and passing the two document’s appian docId as an array of integers.

1 Like

Hello, I’m AiRon, an automated tech support bot :robot:
While you wait for one of our customer support representatives, I can help you with your question.


It seems like you’re encountering an issue with loading documents in Appian using the Apryse WebViewer. The error may be related to how the documents are being accessed or the format in which document IDs are being passed.

Some things you can try:

  • Ensure that the document IDs are being correctly passed as an array of integers and that they correspond to valid documents in Appian.

  • Check if there are any CORS-related issues when accessing the documents. If the documents are hosted on a different domain, ensure that the correct CORS headers are set.

  • Use the debugLog property to log the Appian values to the console for debugging purposes. This can help you verify if the document IDs and other parameters are being passed correctly.

  • Verify that the URL or path to the documents is correctly formatted and accessible from the Appian environment.



Here are some resources that might help you:


Hopefully, this helps you solve your problem while you wait for a human to get back to you.

1 Like

Hi there,

If you add multiple document IDs, it must be a list and it will be merged. Please see this guide for more details:

In addition, you can see in the network panel for the WebViewerRetrieveClientAPI request and check the Payload panel to double check that your documentId is being requested:

best regards,
Kevin

1 Like

The error loading document issue was resolved but now its not highlighting the changes in the pdf while comparing.
On the side panel its showing the changes in each page.
Any idea why its happening?

Here’s the code-

...
              webviewer(
                label: "WebViewer",
                labelPosition: "ABOVE",
                validations: {},
                height: "AUTO",
                hidden: null,
                key: null,
                url: null,
                serviceAPIKey: null,
                appianDocId: { 224563,788333 },
                preflattenDocuments: null,
                documentFolder: cons!FOLDER,
                uploadChunkSize: null,
                userDisplayName: null,
                enableReadOnlyMode: null,
                enabledElements: false(),
                disabledElements: null,
                docAccessConnectedSystem: cons!WebViewer_CS,
                loadAsPDF: false(),
                enableAnnotations: true(),
                notesInLeftPanel: null,
                darkMode: false,
                defaultLanguageCode: null,
                customCSSFileId: null,
                customCSSPath: null,
                enableRedaction: true,
                enableMeasurement: true,
                enableExtractPagesToAppian: true,
                xfdfAnnotationDataValue: null,
                xfdfAnnotationDataSaveInto: null,
                autoExportXfdf: null,
                annotationCommands: null,
                onAnnotationsChanged: null,
                enableDocumentGeneration: true,
                searchTerm: null,
                redactionTerm: null,
                autoApplyRedactionTerm: false,
                enableMultiTabMode: true,
                enableSemanticCompareMode: true,
                automaticSemanticComparison: true,
                mentionableUsers: null,
                mentionsAPIURL: null,
                onMentionsChanged: null,
                enableSignatureRequests: true,
                onStartSignatureWorkflow: null,
                onSelectAssignee: null,
                xfdfDocumentFolder: null,
                signingUsers: a!map(
                  userData: {
                    value: "Test User",
                    email: "test@test.com"
                  }
                ),
                saveAsFilenameTemplate: null,
                disableSaveAsFilenameInput: false(),
                enforceNewSaveAsFilename: true,
                customSubstituteFontURL: null,
                enablePdfEditing: false(),
                enableOfficeEditing: false(),
                enableSignatureEncryption: false,
                configFileId: null,
                customData: null,
                disableAppianMenu: null,
                appianProcessButtons: null,
                timerInterval: null,
                onInterval: null,
                webviewerServerURL: null,
                onCustomEvent: null,
                enableConsoleClear: null,
                debugLog: null
              )
 ....

Hi there,

For the missing comparison highlights, please set the modularUI to true in your WebViewer constructor and let us know if that resolves your issue.

See our components property for more information:

Best regards,
Kevin