Friday, July 6, 2007

I am receiving errors when consuming a Web service; how can I avoid them?

There are many details to consider when consuming a Web service, including the following:

· Avoid using two underscore characters in a parameter name.

· Use of the any element or the anyAttribute attribute is not supported in Web methods.

· Avoid using XLANG/s keywords as a Web service name or Web method name.

· Avoid using Web method parameter types that are not supported by XLANG/s.

· Do not use element names that are C# keywords or will be invalid as a C# identifier in your schemas.

· Avoid Web Services Description Language (WSDL) files with multiple service or port type definitions.

· Web method parameters must be Xml Serializable.

· Avoid references to consumed Web services that contain multi-rooted schemas.

· Avoid referencing Web services with Web methods expecting generic-based parameters such as nullable parameters.

· The WSDL import element is not supported.

Source: Microsoft

No comments: