1. Vaibhav Kak
  2. PowerBuilder
  3. Friday, 1 October 2021 12:26 PM UTC

Hello Team,

We recently moved from PowerBuilder SE Version 2017 Build 1666 to Appeon PowerBuilder SE Version 2019 R2 Build 2353

And we had a old Project for generating service DLL from supplied WSDL file (SOAP webservice).

We were able to call the service using generated DLL in 2017 version, but now the calling is getting failed when below function, from SoapConnection object (pbwsclient.pbl) is called (i.e. in PB2019 version).

[ CreateInstance(ref powerobject obj, string proxyname, string portname) returns long ]

Integer i_Ret
String s_WebServiceEndpointURL // webservice url end-point being used.
String s_WebServiceProxyObjectName // name of webservice proxy-object being used.
PowerObject po_WebServiceProxyObject // powerojbect passed as 'REF'.
SoapConnection nv_SoapConnection // SoapConnection object instance.


//Create the Instance using the Soap Connection object
IF IsNull(s_WebServiceEndpointURL) OR Trim(s_WebServiceEndpointURL) = '' THEN
	i_Ret = nv_SoapConnection.CreateInstance(po_WebServiceProxyObject, s_WebServiceProxyObjectName)
ELSE
	i_Ret = nv_SoapConnection.CreateInstance(po_WebServiceProxyObject, s_WebServiceProxyObjectName, s_WebServiceEndpointURL) // Code failing on this line.
END IF

So, basically an instance of SOAP connection is not getting created.

Please assist in resolving this issue, considering this as urgent.

Best regards,

Vaibhav

 

Accepted Answer
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Monday, 4 October 2021 16:38 PM UTC
  2. PowerBuilder
  3. # Permalink
Ahhh yes ... the old PBX way would have created this dilemma. I would not recommend using a PBX. This is the old PBNI way that many PB features were deployed way back when. However, it can create a mess when migrating (as you now have found out). The PBD "swap" way that I use is a much safer and way less confusing. So what you did by renaming the SoapXxxxxxx objects pointer is one way to get around the problem but yet, you should not have encountered this if everything is drive off the "pbwsclient" PBD *properly*. Sounds like you still have some old objects in your App's PBLs from the PBX days that need to be deleted.
Comment
There are no comments made yet.
Vaibhav Kak Accepted Answer Pending Moderation
  1. Saturday, 2 October 2021 06:07 AM UTC
  2. PowerBuilder
  3. # 1

Yes Chris. We did replace the old "pbwsclient170.pbd" library with the newer "pbwsclient190.pbd" library in our PB App's Library List. 

Regards,

Vaibhav

Comment
  1. Chris Pollach @Appeon
  2. Sunday, 3 October 2021 20:49 PM UTC
Excellent! Also, make sure that any objects are listed in the pbwsclient190 PBD are also *not* duplicated in any of your other PB App's libraries.
  1. Helpful 2
  1. Vaibhav Kak
  2. Monday, 4 October 2021 07:27 AM UTC
Thanks! Chris, that was really helpful. While searching for duplicates, it was noticed that in pbwsclient library, SOAPCONNECTION and SOAPPBCOOKIE were still referring to pbwsclient170.pbx file instead of pbwsclient190.pbx file. Just did that change manually and it worked!



global type soapconnection from nonvisualobject native "pbwsclient190.pbx"

global type soappbcookie from nonvisualobject native "pbwsclient190.pbx"



I am assuming this issue to be related to how build was created, kindly confirm on same.



Cheers!



Best regards,

Vaibhav
  1. Helpful
There are no comments made yet.
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Friday, 1 October 2021 14:17 PM UTC
  2. PowerBuilder
  3. # 2

Hi Vaibhav;

   When you migrated from PB 2017Rx to PB 2019Rx - did you replace the old "pbwsclient170.pbd" library with the newer "pbwsclient190.pbd" library in your PB App's Library List?

Regards... Chris

Comment
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.