1. Sally D
  2. PowerBuilder
  3. Monday, 11 March 2019 13:28 PM UTC

Hi all,

 

When i try to use the PB web service assembly to replace EA server, i find there is an issue when using the Any type in PB. When depoly the PB code as dll, the PBNumber coulnd not convert to PBAny type in the dll. How to solve that? Or that is not suported in the assembly?

 

Thanks,

Sally

Kevin Ridley Accepted Answer Pending Moderation
  1. Tuesday, 12 March 2019 14:11 PM UTC
  2. PowerBuilder
  3. # 1

We really have no idea what you are trying to do, so it's impossible to say.  There's a lot you can do with strings and arguments.  You can pass either a JSON or XMLstring to a function and parse the string to get the arguments' types and values.  Again, no idea what you are trying to do, but hopefully that will help for your datawindow arguments.

Comment
  1. Sally D
  2. Wednesday, 13 March 2019 02:44 AM UTC
Sorry, let me make it clear. When retrieve(Any), the parameter is Any type, then the error occurs in the assembly. But as the parameter is the uniform function, so we need to define the datatype to Any first. Then according to the datawindow arguments to set the Any type to specific.
  1. Helpful
  1. Kevin Ridley
  2. Thursday, 14 March 2019 13:01 PM UTC
You have all the info you need to make it work. .NET doesn't understand "Any", I advised you to use string.
  1. Helpful
There are no comments made yet.
Sally D Accepted Answer Pending Moderation
  1. Tuesday, 12 March 2019 07:43 AM UTC
  2. PowerBuilder
  3. # 2

As we need to use datawindow.table.arguments to get the datatype, so need to use Any at the beginning. Thanks for replying. Then it we need decide the datatype by the datawindow argument, we need to change that logical?

 

Thanks,

Sally

Comment
There are no comments made yet.
Kevin Ridley Accepted Answer Pending Moderation
  1. Monday, 11 March 2019 15:37 PM UTC
  2. PowerBuilder
  3. # 3

.NET doesn't know what a PB Any datatype is, so it won't work.  You need to make your function more specific and return a datatype .NET can work with.

Comment
  1. Chris Pollach @Appeon
  2. Monday, 11 March 2019 19:41 PM UTC
Kevin is correct.
  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.