Hi All I am trying to host a WCF service that consumes and spits JSON data. I have this service running on my local development environment however I just cant get this to run on discountasp.net servers here. The problem (after much digging) seems to stem from the fact the to run JSON enabled web services I need to use webHttp binding (damn thing doesnt run on anything else!) and I can not get my WCF service to run on webHttp here. I would much appreciate if someone could help me with this. Is there any tutorial/sample/example code that shows how to code, configure and host on discount asp a simple WCF service that runs on webHttp and works with JSON? Many thanks Nik Post Edited (matrix) : 9/23/2008 8:53:53 AM GMT
Thanks for the link. That actually was not what I was looking for as it tries to configure WCF service to run with ASP.NET AJAX whereas I was looking for a more generic solution. I have managed to get my code up and running. Not surprisingly it was a hell load of minute configuration settings that prevented my service from being called. I have now however managed to sort out my issues! I can now post a tutorial or a guide on how to get up and running a generic REST based WCF service that can be consumed by callers with and without .NET framework using more generic javascript frameworks like jquery etc. If anyone reading this is interested then simply drop in a comment here and I would work on it! Thanks for everyone who read this problem!
I found this on MSDN: http://msdn.microsoft.com/en-us/library/bb763177.aspx What does the system.serviceModel element of your web.config look like? Aristotle DiscountASP.NET www.DiscountASP.NET
To matrix Thanks, I will take up on your offer. Tutorial would be great. Thanks again. PS - also looking to set my first 3.5 Ado.Net DataService on DiscountAsp.net host. was wondering if you have had any luck. My DataService service throws "IIS 7.0 hosting - unauthorized 401 error - multiple authentication enabled" error.
Mike I would surely knock off a tutorial as soon as I get a moment to breath! As for the multiple authorization error, well with WCF one thing I have noticed particularly. WCF masks the exceptions in a very weird way. I kept on getting the same exception for like an eternity and when I actually rolled up my sleeves and dug deep in the myriad log files it turned out that it was actually a problem with the binding and nothing to do with authorization. Make sure your bindings and the end points are set up right. If you could post your web.config and the svc file (assuming you have one) here I can have a quick look and help you with it. Cheers! matrix