At the moment we have big Crashes in our primary application.
Background information:
We currently use the Active X component (COM object) called PDF X change Viewer SDK. We use this component to read and annotate documents in our Digital environment. The Digital environment is a Sharepoint 2013 environment in which the Active X component is built into a separate webpage. This webpage is hosted within the SharePoint platform. SharePoint opens this webpage when you click on a document link in SharePoint. Based on the "SharePoint document Id", the full http location of the file is given to the Active X object, then it opens the file so that the user can work with it.
This is done with the code below
Code: Select all
public void InitPdfViewer(string datfile)
{
axCoPDFXCview.SetDevInfo("XXXSECRETXXX", "XXXSECRETXXX");
if (!String.IsNullOrEmpty(datfile))
{
axCoPDFXCview.LoadSettings(datfile);
}
axCoPDFXCview.SetProperty("View.Bars[\"Menu\"].Visible", "false");
axCoPDFXCview.SetProperty("View.Bars[\"Properties\"].Visible", "false");
axCoPDFXCview.SetProperty("View.Bars[\"Zoom\"].Visible", "false");
axCoPDFXCview.SetProperty("View.Bars[\"CommentAndMarkup\"].Visible", "false");
axCoPDFXCview.SetProperty("Commands[\"Save\"].State", "Offline", 0);
axCoPDFXCview.SetProperty("PageDisplay.DefaultZoom", "FitWidth", 0);
axCoPDFXCview.SetProperty("General.AllowAllAccelerators", 1, 0);
axCoPDFXCview.SetProperty("Tools.Active", "Select", 0);
axCoPDFXCview.SetProperty("General.DenyAllContextMenus", 1, 0);
axCoPDFXCview.SetProperty("View.LockAllBars", 1, 0);
axCoPDFXCview.SetProperty("Commands[\"LockAllCmdBars\"].State", "Offline", 0);
// Summarize in Comments menu
axCoPDFXCview.SetProperty("Commands[\"SummarizeAnnots\"].State", "Offline", 0);
// AddReply main menu
axCoPDFXCview.SetProperty("Commands[\"AddReply\"].State", "Offline", 0);
// AddReply in Comments menu
axCoPDFXCview.SetProperty("Commands[#33245].State", "Offline", 0);
axCoPDFXCview.SetProperty("Search.AllowOpenExternalDoc", "false");
axCoPDFXCview.SetProperty("Search.AllowSearchInFolders", "false");
}
Code: Select all
public void OpenDocumentOnPage(string pdfPath, int Pagenumber)
{
try
{
int docId;
int nFlags = 0;
nFlags = (int)PDFXCviewAxLib.PXCVA_Flags.PXCVA_NoUI;
axCoPDFXCview.OpenDocument(FileHelper.GetWebdavUrlFromHttpUrl(pdfPath), string.Empty, out docId, nFlags);
axCoPDFXCview.GetActiveDocument(out docId);
axCoPDFXCview.SetDocumentProperty(docId, "Pages.Current", Pagenumber- 1);
axCoPDFXCview.SetProperty("Search.AllowOpenExternalDoc", "false");
axCoPDFXCview.SetProperty("Search.AllowSearchInFolders", "false");
}
catch (Exception e)
{
MessageBox.Show("PDF Viewer: " + e.Message);
}
}
The Active X object is installed on the client pc’s according to supplier's description of procedure:
Code: Select all
remove old installation
PDFXCview.exe / UnregServer
C: \ Windows \ SysWOW64 \ regsvr32.exe PDFXCviewAx.dll / u
C: \ Windows \ Microsoft.NET \ Framework \ v4.0.30319 \ RegAsm.exe / u PdfAnnotator.dll
Installation new viewer
PDFXCview.exe / RegServer
C: \ Windows \ SysWOW64 \ regsvr32.exe PDFXCviewAx.dll
C: \ Windows \ Microsoft.NET \ Framework \ v4.0.30319 \ RegAsm.exe / codebase PdfAnnotator.dll
Issue:
Under Windows 7 the above solution works correctly (of course the Regasm and regsrv32 path's are pointed to the right location in the install script) and does not have the problems that we now experience under Windows 10. Since Active-X objects do not work on Windows 10 in the Edge browser, our Digital environment is forced to open in Internet Explorer version 11, due a policy. Users generally experience no problems in daily use, but without known reasons it goes wrong several times a day for different users. Internet Explorer then crashes and the PDF X Change process continues to run in the background and cannot be closed.
During a Crash in Internet Explorer:
- The webpage where the file should be loaded keeps busy with the turning circle.
- We tried to close the pdfxchange process via Taskmanager.
- the IE Tab shows a puzzle piece with pdf exchange logo to indicate that the plugin has crashed.
- According to Taskmanager the process is still present, trying again to close, no Access Denied error.
- Task manager icon disappears from taskbar, is now an empty block and can no longer be opened.
- Looked through resource explorer, process "disappeared" directly from list when selecting
- Resource explorer shows 4 Internet Explorer processes. User had a single IE window open, with two tabs.
- IE processes closed by Resource Explorer, after the first resource explorer crashed and the icon disappeared from taskbar, empty block.
- Entire user session is stuck.
- No response to ctrl + alt + del, ctrl + escape, ctrl + alt + end etc.
- Machine off and on again. After that the user can work again for some time.
Some observations form our side:
- When opening a PDF, multiple .tmp files are created in the <user> \ AppData \ Local \ Temp folder. This seems a lot for opening 1 PDF
- Extra tests with the same 2 PDFs each, one in black and white (130 KB) and one in color (6 MB) also result in large temp files totalling around 80 MB.
- If things get stuck, you won't see any temp files coming.
-There are no strange events in the Windows logs
- After a reboot exactly the same PDF opened in IE without any problem.
- Acrobat has no trouble with PDF file as first downloaded from sharepoint.
- Acrobat reports that PDF meets the PDF / A standard.
It is not only the user session that crashed:
- On a workstation we tested it with two active sessions, an admin idle, and a user session active / foreground. When IE crashes, user logged out (that still worked), logged in again as same user, desktop is displayed empty, start bar still visible, nothing can be clicked, with mouse-over start bar we get the 'wait wheel'
- The admin session was made active again, but it also got stuck. Exactly the same symptoms, it seems to work for a while, but within a few minutes the entire machine hangs with the only option of switching on and off.
- When the machine that crashed was taken over by RDP, the RDP session does NOT seem to be broken,
Existing processes seem to hold out for a long time when a crash occurs, it goes especially wrong when processes have to be stopped, or that new processes (especially explorer (file -> open, file -> save) are started.
The only solution that works in our Digital Environment is to restart the computer. The following assumptions apply in the event of a crash:
- The jam does not occur with the same document every time.
- User x can open the document without problems while user y is bothered by it.
-User y can open the "problem" document without problems after the restart.
- User z has never had problems opening documents.
- The jam occurs with both large and small documents.
- The crash can sometimes not occur for a few days and then 3 times in a row with user y.
- All users have the same PC
- In the taskmanager we do not see a spike on memory or CPU before the PC is freezing
Solutions implemented that did not have the desired result:
-We have been upgraded to the latest version of the viewer that was available (release 2018)
-Everything is now registered as 32-bit so that no 64-bit Active X object runs in a 32-bit internet explorer (hence the script above also refers to the 32-bit RegAsm and regsvr32).
- additional exclusion rules have been added in the Symantec EndPoint Protection Manager 2:
C: \ Program Files \ PdfAnnotator \ PDF-Xchange
C: \ Program Files (X86) \ PdfAnnotator \ PDF-Xchange
Possible solutions to be implemented:
- Converting the solution to a javascript solution (however, a Com object will still be used there) This only removes our customization piece from the solution, but still uses a PDF-Xchange viewer.
hopefully you can help us to solve this problem, or have you had this problem before and can offer us a possible solution for it.
I hope to hear from you soon. if needed a full solution and .dat file can be provided in private.
Regards,
René