WCF "Raw" programming model (Web) – receiving arbitrary data

The previous post mentioned how to return arbitrary data from WCF services. To receive data, however, there is one extra step, which I’ll try to explain here. Like returning arbitrary data, the key for accepting arbitrary (in any format) data is for a method to have a parameter with type System.IO.Stream. This parameter needs to be the single…


WCF "Raw" programming model (Web)

I’ve seen quite a few times in the forums people asking how to control exactly how the data returned by a WCF service. People want to use a certain format for the output of the data which isn’t (natively) supported by WCF, such as XML or JSON. A few examples of questions of this nature:…


Writing custom requests to simple WCF services

Quite often one needs to talk to a WCF service, but using a (WCF) proxy is not a viable alternative. Sometimes the language used isn’t a .NET one, the client might not have the .NET framework installed, or the overhead of the proxy is too big for the application need. In this case, creating a…