Tag Archives: c#

Video Tutorial – Setting up LINQPad for Use with Sitecore


Not sure if this is Sitecore removing the training wheels and bib or movin’ on up to the east side, but as of version 7.1, Sitecore is deprecating the Developer Center and removing it shortly thereafter. As soon as I heard, I reached out to Alex Shyba (@alexshyba) and he pointed me to LINQPad. The LINQPad site had no mention of Sitecore, so I went on a Google scavenger hunt and found Adam Conn’s blog post that covered the steps, along with some pointers Jim Scott’s Coding Blog.

It wasn’t all smooth sailing for me and I was at an hour or two in until I got the everything to work, so I thought why not do a video walkthrough and save my readers the headache.

The video is embedded below and the link to the configuration file is posted to my GitHub here.
Continue reading

How To Build a JSON Web Service to Send Mail in ASP.Net

I was pleasantly surprised to see the traffic analytics on a post I wrote a while ago on Using jQuery to Send Email with Web Services. However, I found some who were still requiring assistance writing the actual .NET web service. Here you go.

In Visual Studio, when you create a web service (ASMX), the default format is SOAP. You will need add a couple of attributes to the code to make it return results in a true JSON format.

  1. First requirement is that you do a POST, but the AJAX call already takes care of that.
  2. Your class is going to need the

    attribute so that you can call the web service from javascript.

  3. Your method responsible for sending mail will need this attribute:
    [ScriptMethod(UseHttpGet = false,ResponseFormat = ResponseFormat.Json)]

Continue reading