Wiki Home

VFP Web Service Client Parameters

Namespace: VFP
Description: Looking for an alternative to passing positional parameters when using VFP as a soap client. Is there a way to use _ws3client.wshandler to accept an object, array or dataset?

I am getting the "too many arguments" on a web service call that has more than 26 parameters. Open to any workarounds? Here is my call:

* Updatelegal
lvResult = .oErXWebService.UpdateLegals(.cauthenticationstring,.cerxtransactionid,;
	IIF(.nLegal_Type <> 0, TRANSFORM(.nLegal_Type),""),;
	IIF(.oValues.Neighborhood_Type_ID<>0, TRANSFORM(.oValues.Neighborhood_Type_ID),""),;
	.oValues.Page, ;
	.oValues.Phase, ;
	.oValues.Partial_Lot, ;
	.oValues.Acreage, ;
	.oValues.Quarter_Section2, ;

The WSDL is located at:

Sorry, I'm not authorized to give out the authentication for this (in fact, I may be giving out more info than they want for this, but I'm desparate.)

Did you write the web service? In VFP? If so, then the way I did one was to use a cursor as a parameter object and convert it to XML and pass it as one long string using XML To Cursor and Cursor To XML. -- Chad Bourque
VFP can accept an object as a return value from a WS call, but it is unable to serialize one out. This is a limitation of the FFC code, I think, and not a hard and fast rule. You may want to check out Rick Strahl's free wwSOAP class to find out if he has worked around this limitation. VFP is limited to 26/27 parameters in calls - that's a hard and fast one. Chad's suggestion of serializing the parameters with Cursor To XML was a work-around I proposed for a client, also, and it worked for them. -- tr
Thanks. No, I did not write the web service so changing how it accepts parameters is not an option for me. (unless I can convince them to do so) - I have used wwSoap before they had provided wsdl based services and it worked pretty well. I think I will go back and check that out again. I think the serialization, as far as I can tell, happens in the soap3 client and not the FFC classes. I was actually thinking I could change the FFC classes to take an XML string and embed that directly into the soapclient but it doesn't look like that is possible. -- Randy Jean
Couldn't figure out how to get wwSoap to work again (these web services changed from java to .NET so my old code would not work for some reason.) Anyway, here is the code. It's very ugly, but it works. -- Randy Jean

Could not get this link to work in IE or Firefox:

This one works in Firefox:
ftp://wikiuser:[email protected]/Files/soapcode.txt

Category Web Services
Contributors: Randy Jean
( Topic last updated: 2004.07.24 12:08:22 PM )