Passing “NULL” to a SOAP web service in ActionScript 3

If you get this error when you search a “NULL” string :


   soapenv:Server.userException
   coldfusion.xml.rpc.CFCInvocationException: [coldfusion.runtime.MissingArgumentException : The SEARCHSTRING parameter to the getFacultyNames function is required but was not passed in.]

You can put the “NULL” data as CDATA values to avoid encoding issues.

You can also try to extend the SOAP encoder in the FLEX application.

Or just modify the XML encoder mx.rpc.xml.XMLEncoder :

if (content != null)
   result += content;