Open document with ActiveX/OLE Integration crashes VM

PDF-XChange Editor SDK for Developers

Moderators: TrackerSupp-Daniel, Tracker Support, Paul - Tracker Supp, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Ivan - Tracker Software, Tracker Supp-Stefan

Forum rules
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.

When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
Post Reply
RoGraf
User
Posts: 13
Joined: Tue Mar 20, 2018 10:39 am

Open document with ActiveX/OLE Integration crashes VM

Post by RoGraf »

We use the Editor within an OLE-Frame inside an RCP (Eclipse) Application. Everything is fine as long as we keep the Editor open. Once closed opening a new View with an embedded OLE-Frame the whole Application crashes.

I think the reason may be the architectural problem (only one INST) mentioned in a couple of threads (eg. viewtopic.php?f=66&t=28922&p=112186&hil ... ce#p112186 or viewtopic.php?f=66&t=25069&p=98153&hili ... ent#p98153).

We create a new SWT Controll site like this:

Code: Select all

new OleControlSite(oleFrame, SWT.NONE, "PDFXEdit.PXV_Control.1")
this works fine but if the oleFrame is disposed, the controllsite is also disposed an the Lib is being unloaded which ist maybe a kind of "Finalize". When we try to open an new controlsite the VM crashes

Because of the hundreds of Documents opened every day we have no chance to keep all this frames/Windows open.
Question is the a solution for the Problem? How do other ActiveX-Application solve this Problem?

Here is a Part of the crash stacktrace:
Unhandled exception
Type=Segmentation error vmState=0x00000000
J9Generic_Signal_Number=00000004 ExceptionCode=c0000005 ExceptionAddress=26E21453 ContextFlags=0001007f
Handler1=6ACE99C0 Handler2=6F729060 InaccessibleReadAddress=03BD63B4
EDI=0000EAC4 ESI=03BD63AC EAX=00000000 EBX=00360000
ECX=00002C84 EDX=251D96A4
EIP=26E21453 ESP=0060F78C EBP=0060F7C8 EFLAGS=00010207
GS=002B FS=0053 ES=002B DS=002B
Module=C:\Program Files (x86)\Tracker Software\Editor SDK\Bin\PDFXEditCore.x86.dll
Module_base_address=26DF0000 Offset_in_DLL=00031453
Target=2_90_20180425_385365 (Windows 7 6.1 build 7601 Service Pack 1)
CPU=x86 (8 logical CPUs) (0x3fa78c000 RAM)
----------- Stack Backtrace -----------
DllUnregisterServer+0x28a3 (0x26E21453 [PDFXEditCore.x86+0x31453])
PXV_GetInstance+0x11e3d (0x26E52D7D [PDFXEditCore.x86+0x62d7d])
(0x3E99A13B)
(0xD8375C20)
(0x76F78475)
(0x124E3992)
(0xFC6859E8)
Sasha - Tracker Dev Team
User
Posts: 5522
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: Open document with ActiveX/OLE Integration crashes VM

Post by Sasha - Tracker Dev Team »

Hello RoGraf,

The logic should be to create One IPXV_Inst at the start of your program and Shutdown it just before the program exit.

Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
RoGraf
User
Posts: 13
Joined: Tue Mar 20, 2018 10:39 am

Re: Open document with ActiveX/OLE Integration crashes VM

Post by RoGraf »

The Question ist - how! ActiveX-Control is open or not - if you close the Canvas - the Control will die.

Wie instanciate the IPXV_Control and get the Inst() of it. To prevent the control to close everything I would have to close only the IPXV_Control and save the IPXV_Inst - right?
How do I only close the Control - I may catch the dispose but ther is no posibility to disconnect the Control and the Inst.
Sasha - Tracker Dev Team
User
Posts: 5522
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: Open document with ActiveX/OLE Integration crashes VM

Post by Sasha - Tracker Dev Team »

Hello RoGraf,

Before initializing all of the Controls, create new IPXV_Inst and then Init it. Then work with your controls - the IPXV_Inst will be the same as you created. Then, when you close your application, Shutdown the IPXV_Inst that you have created.

Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
RoGraf
User
Posts: 13
Joined: Tue Mar 20, 2018 10:39 am

Re: Open document with ActiveX/OLE Integration crashes VM

Post by RoGraf »

Hi Alex,

opening an INST ist not possible when you embed the AxtiveX-Control in Java Ole-Controll will do this but seems we solved the problem - better Tracker did - with the new SDK (V7.0.328.2) no crash occured anymore.

So - Task is closed!
Sasha - Tracker Dev Team
User
Posts: 5522
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: Open document with ActiveX/OLE Integration crashes VM

Post by Sasha - Tracker Dev Team »

:)
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
Post Reply