• How to Enable CORS in the ASP.NET Web API

     

    Have you ever come across the following error:
    Cross-Origin Request Blocked. The same origin policy disallows reading the resource”.
    Us too! It turns out, we get this error due to lack of CORS support while sharing resources. When we try to consume the Web API from origin A in a web application residing in origin B, we get the above error. To solve this error, we need to have a good understanding of CORS…
    • Mon, Aug 31 2015
  • Validating User Input on a Form in Angular JS

     

    I have often seen entry-level developers struggling with user input validation in AngularJS single page applications. In this post, I will give a quick but useful introduction of validations in AngularJS; consider this post as a base learning document from which you can do further learning.
    Let’s start with an example as shown in the image below. You have a registration form with three fields with the following restrictions…
    • Wed, Aug 26 2015
  • Creating an ASP.NET Web API using the Entity Framework Code First approach and the Repository pattern

    In this article, we will learn how to create an ASP.NET Web API using the Repository pattern and the Entity Framework code first approach. Essentially you’ll learn how to:

    1.       Create a core project which will contain entity and the repository interface;

    2.       Create an Infrastructure project which will contain database operations code using the Entity Framework code first approach;

    3.       Create a Web API to perform CRUD…

    • Mon, Aug 10 2015
  • Getting Started with the ASP.NET Web API - Webinar Recap

    On July 24th we hosted a webinar on “Getting started with ASP.NET Web API” for the Indian region and we’d like to share the presentation and recorded webinar with you now! In the webinar, we explored:

    • An intro to the Web API
    • How to write your First Web API using Scaffolding
    • Consuming Web API in jQuery and IGGrid
    • Enabling CORS
    • Code First and Repository Pattern in Web API

    You can find the recording…

    • Thu, Aug 6 2015