Hi, I've just taken over a cf project with very little experience (not my choice unfortunately). I seem to be figuring it out ok but I've hit a problem that I just can't get past. Basically, the code uses cfinvoke to call a method on a webservice, which returns an object. Previously the system worked fine, but I've had to add an extra field (also a complex object) to the object that is returned by the webservice, and since then I get an error, saying 'Could not perform web service invocation'. I've run the web method directly and it works fine, so I've got some idea that the cf code is trying to interpret the extra field in the returnvariable object somehow and as it doesn't expect it, it's causing it to fail. I'm sure this will be fairly obvious to anyone with a decent understanding of CF but I'll admit I am stumped at the moment. Any help greatfully recieved. Thanks in advance! Alun
I am guessing that if you instantiate it as a component rather than a webservice that it works right? Typically, webservices do not return CFC instances, since they are platform specific to ColdFusion. Think about it this way- Say that instead of a ColdFusion app consuming the webservice, that the consumer was a Django application. What would it do with the returned object that you are trying to pass? Are you just returning the object to get a handle on the state of the properties that it contains or are there specific methods that you want to run in it? If you are basically returning a glorified structure with getter/setter methods, than what about returning a serialized (JSON perhaps?) structure of the data you need? Am I generally catching the drift of your problem?
Can you post the code for the web service call that works and the code for the web service call that doesn't work?