Join us for an engaging webinar, as we unravel the potential of AI for revolutionizing document management.
Watch Now
Enable your employees to remain productive throughout the document management process.
Read More
Learn how SmartZone uses a regular expression engine integrated into the recognition engine to achieve the best possible accuracy on data that can be defined by a regular expression.
Docubee is an intelligent contract automation platform built to help your team success
With PrizmDoc Viewer, can I have more than a single viewer on the same page?
Yes, just initialize a second viewer on another <div> in the page. You can use the initialization code here more than once within the same page.
<div>
How do I remove XMP Data from my image using ImageGear .NET?
When removing XMP data in ImageGear, the simplest way to do this is to set the XMP Metadata node to null, like so:
ImGearSimplifiedMetadata.Initialize(); doc.Metadata.XMP = new ImGearXMPMetadataRoot();
Or, you can traverse through the metadata tree and remove each node from the tree:
// Example code. Not thoroughly tested private static void RemoveXmp(ImGearMetadataTree tree) { ArrayList toRemove = new ArrayList(); foreach (ImGearMetadataNode node in tree.Children) { if (node is ImGearMetadataTree) RemoveXmp((ImGearMetadataTree)node); if (node.Format != ImGearMetadataFormats.XMP) continue; toRemove.Add(node); } foreach (ImGearMetadataNode node in toRemove) tree.Children.Remove(node); }
How do I change the default directory of the SmartZone folder from %TEMP% to something else?
As SmartZone runs, it will create a folder in the %TEMP% directory containing a few files that the engine needs to run. If you want to change this location, you can do that by creating an INI file in the same directory as the executable that runs your application. You must name that INI file smartzoneengineloader.ini. The contents of smartzoneengineloader.ini should look like this:
smartzoneengineloader.ini
[smartzoneengineloader] tempdir = C:\Your\Path\Here\
Why do I get a “File Format Unrecognized” exception when trying to load a PDF document in ImageGear .NET?
You will need to set up your project to include PDF support if you want to work with PDF documents. Add a reference to ImageGear24.Formats.Pdf (if you’re using another version of ImageGear, make sure you’re adding the correct reference). Add the following line of code where you specify other resources:
ImageGear24.Formats.Pdf
using ImageGear.Formats.PDF;
Add the following lines of code before you begin working with PDFs:
ImGearFileFormats.Filters.Insert(0, ImGearPDF.CreatePDFFormat()); ImGearPDF.Initialize();
The documentation page linked here shows how to add PDF support to a project.
When specifying the Amazon AWS access keys or IAM Role associated to the S3 bucket, what are the minimum necessary rights that I need to have for licensing to function?
The security policy associated to the IAM Role or User who has access to the S3 bucket needs to contain specific S3 bucket rights below:
listObjects
putObject
deleteObjects
Can I host multiple PrizmDoc viewers on a single page?
It is possible to host multiple viewers on a single page. The following example leverages Bootstrap’s tab implementation:
<!DOCTYPE html> <html lang="en"> <head> <!-- Metadata --> <meta charset="utf-8" /> <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" /> <meta name="description" content="" /> <!-- Title --> <title>AccuSample</title> <!-- Libraries --> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/7.0.0/normalize.min.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.0.0/css/bootstrap.min.css"> <!-- PrizmCSS --> <link rel="stylesheet" href="https://pcc-demos.accusoft.com/static/viewer-latest/css/viewercontrol.css"> <link rel="stylesheet" href="https://pcc-demos.accusoft.com/static/viewer-latest/css/viewer.css"> <!-- Inline Stylesheet --> <style> body { overflow-y: hidden; } #viewer1, #viewer2 { height: calc(100vh - 3em); width: 100%; } </style> </head> <body> <!-- #main --> <main class="container"> <ul class="nav nav-tabs" role="tablist"> <li class="nav-item"> <a class="nav-link active" id="viewer1-tab" data-toggle="tab" href="#viewer1">Viewer 1</a> </li> <li class="nav-item"> <a class="nav-link" id="viewer2-tab" data-toggle="tab" href="#viewer2">Viewer 2</a> </li> </ul> <div class="tab-content"> <div class="tab-pane fade show active" id="viewer1" role="tabpanel"> <div id="viewer1"> </div> </div> <div class="tab-pane fade" id="viewer2" role="tabpanel"> <div id="viewer2"> </div> </div> </div> </main> <!-- Libraries --> <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.1/umd/popper.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.0.0/js/bootstrap.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/underscore.js/1.8.3/underscore-min.js"></script> <!-- PrizmJS --> <script src="https://api.accusoft.com/v1/docstore/viewer/assets/classic/bundle.js"></script> <script src="https://pcc-demos.accusoft.com/static/viewer-latest/js/jquery.hotkeys.min.js"></script> <script src="https://pcc-demos.accusoft.com/static/viewer-latest/js/viewercontrol.js"></script> <script src="https://pcc-demos.accusoft.com/static/viewer-latest/js/viewer.js"></script> <!-- Inline Script --> <script> var viewingSessionId1; var viewerControl1; var viewingSessionId2; var viewerControl2; $(document).ready(function() { $.ajax({ "type": "post", "url": "https://api.accusoft.com/PAS/V1/ViewingSession", "headers": { "acs-api-key": "" }, "data": JSON.stringify({ "source": { "type": "url", "url": "" } }) }).done(function(response) { viewingSessionId1 = response["viewingSessionId"]; // Initialize viewer viewerControl1 = $("#viewer1").pccViewer({ documentID: viewingSessionId1, imageHandlerUrl: "https://api.accusoft.com/v2/viewers/proxy", language: languageItems, template: htmlTemplates }).viewerControl; }); $.ajax({ "type": "post", "url": "https://api.accusoft.com/PAS/V1/ViewingSession", "headers": { "acs-api-key": "" }, "data": JSON.stringify({ "source": { "type": "url", "url": "" } }) }).done(function(response) { viewingSessionId2 = response["viewingSessionId"]; // Initialize viewer viewerControl2 = $("#viewer2").pccViewer({ documentID: viewingSessionId2, imageHandlerUrl: "https://api.accusoft.com/v2/viewers/proxy", language: languageItems, template: htmlTemplates }).viewerControl; }); }); </script> </body> </html>
What is the absolute bare minimum I need to use PrizmDoc Cloud?
This will allow you to load a document via a URL using PrizmDoc Cloud. Just include your PrizmDoc Cloud API key in the POST request headers.
Please note: This is purely intended as a proof-of-concept. You should never include your API key in your client-side Javascript.
<!DOCTYPE html> <html lang="en"> <head> <!-- Metadata --> <meta charset="utf-8" /> <meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="description" content="" /> <!-- Title --> <title>AccuSample</title> <!-- Libraries --> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/8.0.0/normalize.min.css"> <!-- PrizmDoc CSS --> <link rel="stylesheet" href="https://raw.githack.com/Accusoft/hello-prizmdoc-viewer-with-nodejs-and-html/master/public/viewer-assets/css/viewercontrol.css"> <link rel="stylesheet" href="https://raw.githack.com/Accusoft/hello-prizmdoc-viewer-with-nodejs-and-html/master/public/viewer-assets/css/viewer.css"> <!-- Inline Stylesheet --> <style></style> </head> <body> <!-- #viewer --> <div id="viewer" class="pccv pcc-full-screen"></div> <!-- Libraries --> <script src="https://raw.githack.com/Accusoft/hello-prizmdoc-viewer-with-nodejs-and-html/master/public/viewer-assets/js/jquery-3.4.1.min.js"></script> <script src="https://raw.githack.com/Accusoft/hello-prizmdoc-viewer-with-nodejs-and-html/master/public/viewer-assets/js/jquery.hotkeys.min.js"></script> <script src="https://raw.githack.com/Accusoft/hello-prizmdoc-viewer-with-nodejs-and-html/master/public/viewer-assets/js/underscore.min.js"></script> <!-- PrizmDoc JS --> <script src="https://raw.githack.com/Accusoft/hello-prizmdoc-viewer-with-nodejs-and-html/master/public/viewer-assets/js/viewercontrol.js"></script> <script src="https://raw.githack.com/Accusoft/hello-prizmdoc-viewer-with-nodejs-and-html/master/public/viewer-assets/js/viewer.js"></script> <script src="https://raw.githack.com/Accusoft/hello-prizmdoc-viewer-with-nodejs-and-html/master/public/viewer-assets/js/viewerCustomizations.js"></script> <!-- Inline Script --> <script> let viewingSessionId; let viewerControl; $(document).ready(function() { $.ajax({ "type": "POST", "url": "https://api.accusoft.com/prizmdoc/ViewingSession", "headers": { "acs-api-key": "4lTamQVZmrkqZhH8cZhdu7L0xyhUa3gorcaCFQpA_zmuowZs4zoF39V4IckpnVW_" }, "data": JSON.stringify({ "source": { "type": "url", "url": "https://www.usability.gov/sites/default/files/creating-wireframes.pdf" } }) }).done(function(response) { PCCViewer.Ajax.setHeaders({ "acs-api-key": "4lTamQVZmrkqZhH8cZhdu7L0xyhUa3gorcaCFQpA_zmuowZs4zoF39V4IckpnVW_" }); viewingSessionId = response["viewingSessionId"]; // Initialize viewer viewerControl = $("#viewer").pccViewer({ "documentID": viewingSessionId, "imageHandlerUrl": "https://api.accusoft.com/prizmdoc", "language": viewerCustomizations.languages["en-US"], "template": viewerCustomizations.template, "icons": viewerCustomizations.icons, "annotationsMode": "LayeredAnnotations" }).viewerControl; viewerControl.on("ViewerReady", function() { console.log("Ready!"); }); }); }); </script> </body> </html>
In PrizmDoc, my text annotation won’t fit the bounding box as if there is padding on the text. How can I fix this?
Check to see if there’s any custom styling to the body tags. If you have any sort of padding applied to the “body” element in the CSS, it may affect the text annotation, which is a foreign object with a body tag in it.
When using the PrizmDoc samples, the sample documents included are taking close to 1 minute to load in the viewer. The same also happens when uploading files into the sample.
The server processes are showing minimal impact on CPU and memory. However, the hard drive was spiking to 100% utilization sporadically.
We have found that Windows Defender with enabled Real-Time scanning can significantly impact performance. Once Real-Time scanning was disabled, we found this issue to be immediately resolved.
To disable Windows Defender, you can do the following:
Control Panel
Windows Defender
Settings
Off
Why am I seeing requests sent through pcc.ashx when they shouldn’t be?
The default option for the imageHandlerUrl is pcc.ashx so if, for instance, you misspelled imageHandlerUrl or in some other way do not have the setting properly implemented, you will see requests sent through pcc.ashx.
imageHandlerUrl
This has been seen when trying to set up the pas-service reverse proxy redirect for Prizm Application Services (PAS).
A sample implementation of this setting can be found in the viewer.js around line 288.
viewer.js
options.imageHandlerUrl = options.imageHandlerUrl || "../pcc.ashx";
By default, in the PrizmDoc Viewer, links are highlighted and underlined in blue. To follow links within a document, the user needs to click the link, wait for the floating popup to appear showing the link’s target URL, and then click that to actually follow the link. Is there a way to make this a single-click process and skip the floating popup?
The desired one-click functionality can be achieved by modifying the viewer.js source file:
Inspect around line ~9457; you’ll find the following else if block:
else if
} else if (ev.targetType === "documentHyperlink") { hyperlinkMenuHandler(ev, "view"); }
This line of code executes when the user clicks on a link displayed within the Viewer. The call to hyperlinkMenuHandler is responsible for displaying the floating popup. If you’d like to immediately open the link in a new window/tab instead, replace the contents of the “if else” block with a call to window.open:
hyperlinkMenuHandler
window.open
} else if (ev.targetType === "documentHyperlink") { window.open(ev.hyperlink.href, '_blank'); }
This will allow hyperlinks that appear in the Viewer to be followed in a new window/tab with a single-click.
On Windows, are there any restrictions on the type of account that I can install PrizmDoc under? If so, what are they?
The account that you install PrizmDoc under has to be part of the Local Administrators group. As the installer creates Windows services, administrative-level permissions are required.