I have the same source code in pb10.5 and pb2022, both compiled in 32-bit.
In pb105, using the command CONNECTTONEWOBJECT("classolecomNONONONO") works.
However, in pb2022 it always returns -3.
What is the cause? How can I solve it?
I have the same source code in pb10.5 and pb2022, both compiled in 32-bit.
In pb105, using the command CONNECTTONEWOBJECT("classolecomNONONONO") works.
However, in pb2022 it always returns -3.
What is the cause? How can I solve it?
Partially solved!
How? Generating the executable in PowerBuilder 2022 and running it through the generated executable works.
Unfortunately, I have come to the conclusion that the problem is certainly in the PB2022 IDE.
However, if I need to debug it, I won't be able to. Because it doesn't work through the IDE (it always returns -3).
For the registry to work (regsvr32) you need to have the dotnet core 6.0 runtimes
For List Runtimes in (CMD) Command line: "dotnet --list-runtimes"
Result OK:
Microsoft.NETCore.App 6.0.35 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.WindowsDesktop.App 6.0.35 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Hi Fabio,
I suggest you submit a bug to Appeon Support System at https://www.appeon.com/standardsupport/newbug so that we can better analyze this problem. When you submit the bug, please:
1. Please input the specific PB version you are using.
2. Please provide all the DLLs that would be used by OLE. Because I’ve tried REGSVR32 registering the DLL you provide in Community but failed.
3. Please provide a small case that can reproduce this problem and it would be better if you can also provide a case that works fine in PB 10.5. I would like to upgrade it version by version to check each PB version so that we can find out in which PB version the problem started.
Regards,
Ken
attached dll/ole used in testing on this forum
Hi, Fabio -
What OLE Server/COM object are you connecting to? Is it available to be downloaded and installed so that I could test, or is it a purchased/licensed product?
What workstation hardware and OS are you running PB 2022 R3 on?
When you start the PB app, did you select Run as Administrator option. The PB app might not have the privileges to access the registry and/or DLLs.
Yes, same machine. Same dll/ole/library.
Hi Fabio;
The -3 means "Object could not be created" and is probably because the OLE Server is not available or the OLE processing in the O/S cannot locate it.
Note that OLE services are handled by the O/S and not PB. The O/S uses the Registry to locate the App by it's Service Name in the registry. So this type of failure could mean that the OLE server is not registered properly.
Are you testing the OLE feature on the same machine where PB 10.5 is also located?
Regards .. Chris