Creating JSON-enabled WCF services in .NET 3.5(pluralsight.com)
submitted by brianjlowry(640) 4 years ago
From Fritz Onion.
3 comments |category: Web Services |Views: 56 Tweet
tags: WebServices another
Add a live kick counter to your blog >>
You can even customize the image by choosing your own colors, and then clicking the button below to update the preview and the html code:
Simply copy and paste this HTML into your blog post.
posted by brianjlowry(640) 4 years ago 0
Not to be confused with the other article entitled with the same name, this is an update to that article where Fritz shows that JSON-enabling WCF can be done with one line in the config.
Reply
posted by Jemm(9604) 4 years ago 0
Yeah, I noticed this before the other article, but I thought it was more thorough. Also the method described in this post requires one to embed the whole service class right into the .svc file instead of code-behind (not something that I would do in production code)
"Unfortunately, there is no wizard to generate a simple service like this in VS 2008. The best way to use this approach is to generate an Ajax-enabled WCF Service using the wizard, then delete all of the configuration goo it adds to web.config and manually add the Factory="…" attribute to your .svc file. You'll still be using the code-behind model, but you probably should be anyway since it keeps all your code in a single place in the site." Not sure I follow you... it seems as though the code-behind model is enforced...
All tags Your tags
Suggest a new category
dpeterson(1835)
pwhe23(1134)
rcash(540)
vijayst(504)
bsenoff(361)
bnaya(312)
winphonegeek(260)
Matt_TCF(253)
isenthil(250)
Noldorin(235)