Anyone been able to consume a service with attachments in a .NET client?

Has anyone tried to consume a webMethods service that supports binary file attachments in a .NET client application?

I have found that it is nearly impossible to get these to things talking to each other.

It appears that Microsoft has sought to use every single standard in generating service request message to make them as complex as possible…where as webMethods appears to have attempted to use none of them and does not fully support MTOM message standards.

For example, .NET generates HTTP headers for the message part with CONTENT ID containing urls and encoded escape charters (ie This is perfectly acceptable and plent of other java based webservices support this (ie IBM Websphere, JBOSS, axis). Does webMethods? Nope.

This is going on a rant but the frustration level is at an all time high.

If anyone has gotten a .NET client to be able to send binary data to a webMethods web service I would very much appreciate any insight.


Try Base64 encoding, that’s what I have used in the past without any issues. Just another type in your xml payload. Haven’t really tried the MTOM stuff. I’ve found most of the stuff that is suppose to make the message autonomous and inter-operate with everything generally adds more complexity than value.


Thanks Mark.

I have used Base64 as a starting point…but as the file sizes get larger I was trying to improve the transport performance of the services by using the MTOM functionality.

Base64 strings are larger in size than the original file. It’s possible that file sizes may reach as much as 150 MB. At this point we might not even be able to handle that amount of data in any kind of volume but I have to try.