Web Service Proxy Generator
Proxy errors on client workstation
Gravatar is a globally recognized avatar based on your email address. Proxy errors on client workstation
  SamA
  All
  May 24, 2019 @ 01:30pm

I am testing the Proxy generator (to decide if we will purchase) but when I build my test app and copy to a client workstation it always gives an error regarding the web service class not being found (the web service is reachable from that workstation). It runs on my development workstation. In another test it would return an error regarding "DataSettoXmlString" not found.

What am I doing incorrectly?

Thanks

Gravatar is a globally recognized avatar based on your email address. re: Proxy errors on client workstation
  Rick Strahl
  SamA
  May 24, 2019 @ 04:32pm

Not sure about the Web Service error. Can you provide the exact error message?

The DataSetToXmlString() error most likely is due to an error with the data that's being passed to it. The method you might be using is DataSetToXmlAdapter() which calls that method on the .NET service proxy. If you pass a non-dataset object to that method it will fail with error you show here.

You probably need to post your (simplified) code as to what you're calling and what you're doing. Whatever you do after a service call always check for errors before calling other methods.

+++ Rick ---

Gravatar is a globally recognized avatar based on your email address. re: Proxy errors on client workstation
  SamA
  Rick Strahl
  May 28, 2019 @ 03:46pm

I downloaded the proxy generator to test it, I built a small test app (it is below), it works for me on my dev workstation so I wanted to verify it works from a user workstation (prior to purchasing). I copied my VFP test prg, the generated DLL, the bridge component and ipstuff to the users workstation , verified that dotnet version is correct, user can see the web service from a browser. user receives the errors detailed in the first email

DO "CmEcfWebSvcProxy"
LOCAL loProxy as "CmEcfWebSvcProxy"
loProxy = CREATEOBJECT("CmEcfWebSvc.CmEcfWebSvc","v4")
LOCAL loBridge as wwDotNetBridge
loBridge = CREATEOBJECT("wwDotNetBridge")

*** Call a Service method
loCmData = loProxy.GetCmDataCR("1","19-10001","bk")

*** Check for errors
= AERROR(aErrorArray)

*** Convert to cursor (in memory)
loCursor = loBridge.DataSetToCursors(loCmData)
**loXML = CURSORTOXML(0,"test.xml",512,0,"1")
BROWSE last

Gravatar is a globally recognized avatar based on your email address. re: Proxy errors on client workstation
  Rick Strahl
  SamA
  May 28, 2019 @ 03:49pm

Are you sure that the data from the service is returning a DataSet? You can't just turn any kind of result into a dataset - that's a special return type and it's pretty unusual for a server to return a DataSet. If you're just assuming that it's a dataset please take a moment to read through the documentation on how to access the results from the service.

Specifically this topic:

https://west-wind.com/wsdlgenerator/docs/_2km016yg4.htm

and the following ones that deal with array results which is likely what you are actually getting returned.

What is the .NET Signature of the method you are calling on the proxy (or the Web Service endpoint)?

+++ Rick ---

© 1996-2019