This content has been marked as final. Show 2 replies
try returntype = any
Thanks for coming back with a suggestion.
Unfortunately, it results in the same thing.
<cffunction name="StructTest" access="remote" returntype="any">
<cfargument name="argString" required="Yes" type="string">
<cfset var result = structNew()>
<cfset structInsert(result,"Dan","Daniel Mackey")>
<cfset structInsert(result,"Sam","Sam Kidd")>
<cfset structInsert(result,"Peter","Peter Coppinger")>
LPS.WebServiceTest lps = new LPS.WebServiceTest();
map = (LPS.Map)lps.StructTest("Dan");
The same thing occurs.
map.item is null
If I invoke this from ColdFusion, the correct data is returned :-(
The exact C# message is :
"Object reference not set to an instance of an object." and if I test map.item it is in fact Null.
Arrays, Strings, Queries are all working fine.
This is driving me nuts out of principle in that it should be fine.
Map contains item which is an array of mapItems, each with a Key/Value pair.
I could work around it by using an Array of Arrays SOAP type (Convert the struct to an array which each element being a 2 element array for the key/values) but out of principle its eating away at my will to live like a SOAP/C# brain cancer ;-)