Bug 5131

Powerbuilder OLE & Microsoft Word 11 October, 2021

jorge gonzalez
23 August, 2020
Product: PowerBuilder Category: Third Party Software
Version: 2019 R2 Build: 2353
Classification: Sybase (legacy) bug Publishing: Public
Priority: P3
Status: Scheduling Reason:
Mark Lee @Appeon 11 October, 2021
#22
Hi Miguel,
 
Thanks for your update. We will also transfer the info to our development team for consideration.
 
Hi Jorge,
 
Thanks for your detailed explanation of how Word is being used in your real-life environment.

Regards,
Mark Lee
Miguel Leeuwe 11 October, 2021
#21
Ok Jorge, for you the workaround would work.
Regards
jorge gonzalez 11 October, 2021
#20
Sorry Miguel I wasn't very precise. We were running two different Powerbuilder apps that made use of Word. These apps were run automatically via the Window AT scheduler. When we'd run them at the same time they would have problems with Word so we re-scheduled them so they's run at different times. These apps were run on a server so no users were opening Word.
Miguel Leeuwe 11 October, 2021
#19
Hi, the workaround of not using two applications, is no good. 
As I described before, the problem also happens when a user simply opens and closes ms word. For example by double clicking on a word document file in the file explorer.
Regards.
Mark Lee @Appeon 11 October, 2021
#18
Hi Miguel & Jorge,

Sorry for the late reply.
We can reproduce it on our side in PB 12.6 and PB 2019 R2 & R3.
The current way to avoid process collisions is to set the Visible property of OLEObject to True after instantiation.
e.g.
lole_word.Visible   =   True
 
But the workaround will make the Word process visible. Other workaround solutions, as Jorge said, avoid having two applications working on Word at the same time.
 
Anyway,we will escalate this problem to our development team for further analysis. We will need some time to figure it out and we will get back to you if any progress we would make.

Regards,
Mark Lee
Miguel Leeuwe 27 July, 2021
#17
Thank you Mark.
Yes, I'll avoid posting in other people's tickets until this ticket might have been applied: https://www.appeon.com/standardsupport/track/view?id=6799
regards.
Mark Lee @Appeon 27 July, 2021
#16
Hi Miguel,

We will add your email address to the Cc list of this ticket so that you could receive the notification about the update.
 
BTW, it is also suggested you submit a new ticket even though you encounter a similar issue to avoid this kind of situation. You can let us know the related ticket number on the new ticket so that we could better handle them one by one. Thanks in advance.

Regards,
Mark Lee
Miguel Leeuwe 26 July, 2021
#15
Thanks for that.
Please forgive me if I don't respond, since this ticket was not originally made by me, I won't receive any notifications and would only notice any updates by coincidence.
regards
Mark Lee @Appeon 26 July, 2021
#14
Hi Miguel,

Thanks for report the problem. We are working on it and we will get back to you after analyzing it.
We'll keep you posted here!

Regards,
Mark Lee
Miguel Leeuwe 23 July, 2021
#13
Okay, I just re-tested the non-protected word instance and it still fails.

Just run any code like this:
	lole_word = CREATE OLEObject
	lole_word.ConnectToNewObject("word.application")
	lole_word.Application.Visible = False
	lole_word.Application.WindowState = 2
and the put a stop in debug after that code.
You now see one instance of word in the taskmanager.
Then open some word document in the file explorer by double clicking on it (you still see only ONE instance of Word) and then close it. You now have 0 instances of Word in the taskmanager.
Any pb code that would use "lole_word" will blow up at that moment.

regards.
Miguel Leeuwe 22 July, 2021
#12
Sorry about not answering before. Since this ticket was made by Jorge Gonzalez, I'm not getting any notification on updates.
I haven't had the time yet to check if what I described is still happening.
Probably tomorrow I'll have some time to test again and get back to you.
Hi Miguel,

We have been trying to keep in touch with you to find out about the resolution of this issue, we would like to continue with our support but without more information, we are in the need to close it in the next 3 working days, according to our internal help support policy but please remember you can always open a new ticket.  

Regards,
Francisco
Hi Miguel,

I'm just touching base with you about this ticket.
Please let us know if there is something else we can do in order to keep supporting you.  

Regards,
Francisco
armando.herrera 05 March, 2021
#9
Hi Miguel, 

Are you still facing this matter? 
Is there anything else we can do to keep helping?. 

Regards!
armando.herrera 16 February, 2021
#8
Hi Miguel 

We are excited to announce that PowerBuilder 2019 R3 GA version and InfoMaker 2019 R3 GA version, build 2670, are officially released and available for downloading!

https://account.appeon.com/download/2019

Regards!
Miguel Leeuwe 03 October, 2020
#7
I'll check if things still go wrong as explained in my previous comment. If so, I'll make a new ticket.
Miguel Leeuwe 03 October, 2020
#6
One thing I also noticed half a year ago (might have been fixed now by MS, don't know):
When you have an instantiated connection with Word using OLE, you'll see Word in the task manager of windows.
If a user then opens a Word document from the file explorer and closes it, your instantiated connection with word is gone !
Somehow the newer Office versions don't respect your instance and simply take possession of it, or maybe it is powerbuilder not "protecting" the instanciated connection.
I noticed this while using word for spellchecking. I made a global OLE instance, so any time a spell check needs to take place, I don't have to do the ConnectToNewObject() all the time and the spellcheck would be faster. Bad luck though due to this bug.
Regards
armando.herrera 02 October, 2020
#5
Hi Jorge, 


I would like to check with you if the response provided has been helpful enough to resolve your case. If so, can we proceed to close the ticket?.
Otherwise, do let us know if we can provide you with any further assistance and keep in mind that you are always welcome to open another ticket in case you need it.


Regards!
armando.herrera 23 September, 2020
#4
Hi Jorge,

Are you still facing this matter? 
Is there anything else we can do to keep helping?.

Regards!
armando.herrera 11 September, 2020
#3
Hi Jorge, 

This ticket was stopped due to a required test case and we need to collect more information about it, please note that you can also send us a Set of screenshots or a small video showing the case.

Thanks for your understanding!

Regards!
Chris Pollach @Appeon 31 August, 2020
#2
Hi Jorge;

  FWIW: I have seen this issue since way back in the Sybase PB versions as well. Also when using OLE with Excel. The occurrences of this happening - seem to me - to also get more frequent with newer MS-Office versions like 365.

  Hopefully, Engineering can figure out the cause if you can supply a simple test case.

Regards ... Chris
Mark Lee @Appeon 24 August, 2020
#1
Hi jorge,

Thanks for reporting this problem.
1. Are you using the two Powerbuilder apps to open the same doc document?
2. I have built a small case to use the OLE Control to open the Microsoft Word, but I can't reproduce the issue on our side.
Could you provide a sample test case (with PBT / PBL) for us to reproduce the issue for further analysis? Thanks in advance.

Regards,
Mark Lee
jorge gonzalez 23 August, 2020
*Phenomenon:
This is actually a very old problem. If you run two Powerbuilder apps that both connect to Microsoft Word using OLE at the same time they will work but eventually they hang. What causes this and is there a solution? Our solution has been to not run these two apps at the same time.

*Reproduce Steps:


Remarks:
OS:
Windows 10
Platform:
64-bit
Database Type:
IBM DB2 UDB
Database Version:
11