views:

415

answers:

3

WCF service is running with 'wsHttpBinding' Binding. The application which gonna consume WCF Service is non-wcf compliance or in other words, it is on the top of Framework 2.0 and I can't use ServiceModel in this app (since only 3.5 supports ServiceModel).

Any suggestions, how to consume above WCF Service in application built in 2.0?

+2  A: 

This won't work - typically. .NET 2.0 only support basicHttpBinding, or the new REST-style webHttpBinding.

You could potentially retrofit the WSE (Web Services Enhancements) - but that gets quite messy.

marc_s
A: 

ServiceModel is part of 3.0, not 3.5 - but either way I expect you should be able to use WSE3 to connect, since this offers WS*. Jimmy Ziemowit has some thoughts on this here.

In the past I've had success simply deploying System.ServiceModel.dll etc with the app onto 2.0 machines (back in the early days of 3.0); it may work for you too? A full 3.0 install is preferred, of course.

Marc Gravell
A: 

The wsHttpBinding is not compatible with the ASMX-style web references used in .NET 2.0.

If you do not need message-level security, you can switch to a basicHttpBinding, which will make the service consumable by any client (simply use the standard Add Web Reference dialog). If you must use WS-Security then you will either need to upgrade the client to .NET 3.0, or switch to a customBinding and use WSE 3.0 on the client.

(Note that WSE is no longer a supported technology and its use seems to be frowned upon by the community. Only use this if none fo the other solutions will work for you.)

Aaronaught