1. William Hodgson
  2. PowerBuilder
  3. Friday, 15 December 2017 23:11 PM UTC

I have been having problems with opening windows that contain certain OleCustomControls. There seems to be a maximum number of times that I can open a window before the application will crash.

One of the controls that I have this problem with is the Windows Media Player control. If I repeatedly open a window that contains the control, then close it, it will crash after about the 200th opening/closing of the window.

It does not seem to matter if it takes a minute to open/close the window 200 times, or an hour. Explicitly adding GarbageCollect() calls does not seem to help either. We are using PB 12.5.2.

Error:

Faulting application name: test.exe, version: 1.0.0.1, time stamp: 0x51835e47
Faulting module name: jscript.dll, version: 5.812.10240.16384, time stamp: 0x0b3a1bde
Exception code: 0xc0000005
Fault offset: 0x00012763
Faulting process id: 0x3f18
Faulting application start time: 0x01d375f7ec3003fc
Faulting application path: C:\test\test.exe
Faulting module path: C:\Windows\System32\jscript.dll
Report Id: 64d5a668-8fb4-44ce-863c-8db98ca5d0db
Faulting package full name: 
Faulting package-relative application ID: 

 

Does anyone know of a potential fix to this problem?

Hans Herbert Dr. Heynckes Accepted Answer Pending Moderation
  1. Saturday, 16 December 2017 09:05 AM UTC
  2. PowerBuilder
  3. # 1

Embed an additional "standard" ole_control (e.g bitmap) into your window and make it "unvisible". 

Closing the window will clean up (destroy) all other (and your custom) embedded ole controls either.

You should give this simple workaround a try.

I found this behaviour incidentally and with my homebrewed .net activex controls this works well.

Comment
  1. William Hodgson
  2. Monday, 18 December 2017 21:18 PM UTC
Thanks for your response, although embedding an additional invisible ole control does not seem to make a difference.



I still get crashes at the same time that I would without the extra ole control.

  1. Helpful
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.