Ask your technical questions on forums or here :
ASP.NET or MVC | C# | Windows Phone
Microsoft Technology Journals by Abhimanyu K Vatsa
HOME ABOUT RAZOR BOOK SPEAKING MVC ASP.NET JQUERY VIDEOS EBOOK ARCHIVE

7 Dec 2013

Logging Database Operations in Entity Framework 6 - EF6 New Feature

In this blog post you will learn a new feature ‘Logging Database Operations’ introduced with Entity Framework 6. This features works for models created with Code First or the EF Designer.

25 Nov 2013

Seeding ASP.NET Identity Database

In this post you will learn how to seed User’s Profile database tables (AspNetUsers and UserProfileInfoes, we created in last post) with dummy data.

24 Nov 2013

Customizing User's Profile to add new fields in brand new database table

In this post you will learn how to customize User’s Profile and add new fields/properties/columns (FirstName, LastName and EmailID) in a brand new table with ASP.NET Identity System.

23 Nov 2013

Customize User's Profile in ASP.NET Identity System

Note: You should read this post instead, I found below walkthrough will not work on ASP.NET Identity 2. I will re-work on this post soon.

In this post you will learn how to customize User’s Profile and add some more fields like FirstName, LastName, EmailID etc with ASP.NET Identity System. In my last post I listed some of the great new features introduced with Identity system.

19 Nov 2013

ASP.NET Identity System in Visual Studio 2013 - New Feature

In this post you will learn about a very new enhancement in ASP.NET Framework technologies (MVC, Web Forms, Web Pages, Web API and SignalR) known as ‘ASP.NET Identity System’ with the release of Visual Studio 2013. This enhancement well defines the meaning of ‘One ASP.NET’, because this can be used with all ASP.NET Framework technologies more easily than before.

17 Nov 2013

Visual Studio Online Monaco Code Editor Walk-through - Part 2

In the part 1 of this series you learned how to edit compiled websites using Visual Studio Online Monaco Editor. Now in this part you will learn how to edit source code of website. Read my previous post or at least first paragraph of that post.

16 Nov 2013

Visual Studio Online Monaco Code Editor Walk-through - Part 1

In this post series I will show you how we can take advantage of Visual Studio Online “Monaco” to edit codes (HTML, CSS, C#, JavaScript etc) in the browser out of the box.

26 Oct 2013

Multiple identity columns specified for table 'States'. Only one identity column per table is allowed

This post addresses the error that we see when executing Update-Database command inside Package Manager Console. I am going to talk about two continuous error appears and fix is very simple, just read this blog.

25 Oct 2013

Custom Code First Conventions - EF 6 New Feature

In this blog post you will learn a new feature ‘Custom Code First Conventions’ introduced with Entity Framework 6. This is 'Code First' only improvement. EF 6 comes with number of cool new features and improvements, so I decided to write blog posts and cover some of the new features.

20 Oct 2013

Entity Framework 6: New Features

In this blog post you will see the list of cool things available with Entity Framework 6. Entity Framework is Microsoft's recommended data access technology for new applications. EF team recently announced the release of EF6 and it is now available for download on NuGet. EF6 comes with number of features and performance improvements, I have listed some of them below and I will cover most of the cool things of EF6 in coming blog posts.

Area in MVC 5 with example - step by step

In this post you will learn how to create Area in MVC 5, because creating Area in MVC 4 was quite different. In MVC 5 (Visual Studio 2013), Area option can be found under ‘Add Scaffold’ dialog. In this post, I will take you through step by step to setup and running Area in MVC 5.

"Area in MVC 4" is available here.

17 Oct 2013

Debugging MVC with Route Debugger Tool

In this blog let's talk about a really cool tool for MVC developers ‘Route Debugger’. Sometimes a bug in your route can break application because it invokes either an incorrect controller or action. So, do not worry just install this tool in the application and it will make your route debugging easier like never before.

Category and Sub Category in single Drop Down List (DDL) in MVC

In this article you will learn how to create a Drop Down List in MVC that can display States and its associated Districts in a single Drop Down List. You will learn this step by step.

15 Oct 2013

Hands on ASP.NET GridView - eBook by me

I would like to take this opportunity to let you know that C# Corner (MindCracker Community) have combined my 25 Articles on GridView series and published as an eBook with the title "Hands on ASP.NET GridView".

12 Oct 2013

IIS Express immediately shutting down, hence web application stops running, on click 'Stop Debugging' in Visual Studio 2013 IDE

I'm not sure why this change in 2013 IDE for web applications, it was completely different in Visual Studio 2012. In 2012 IDE, when we click on 'Stop Debugging', then IIS Express was continued running hence after any change in web application we just 'Build Solution' (Ctrl + Shift + B) and refresh the browser (specially Chrome). But now in Visual Studio 2013 things where little changed, when we click on 'Stop Debugging', then IIS Express stops running and hence web application also stops running. Let me tell you I didn't make any changes in settings J

10 Oct 2013

Named Routes in MVC

In this post you will learn what are ‘Named Routes’ and how to use them to generate URLs. I will explain this using problem and then solution approach.

7 Oct 2013

Route Constraints in MVC

In this post you will learn how to define ‘Route Constraints’ in MVC Application. Route Constraints allow us to apply a regular expression to a URL segment to restrict whether the route will match the request.

4 Oct 2013

Getting Started with jQuery.tmpl (jQuery Templates) in MVC

In this post you will learn how to use jQuery.tmpl (jQuery Template) JavaScript library in MVC for client side templating. I will take you through few easy steps to setup it and working.

22 Sep 2013

Scaffold your ASP.NET MVC project with the MvcScaffolding package: Video

In this video you will learn how to scaffold the CRUD/Controller/DbContext using MvcScaffolding package developed by Scott Hanselman and Steve Sanderson.

10 Sep 2013

Mustache.js - Getting Started with Mustache.js in MVC: Video

In this video post you will learn how to use Mustache.js JavaScript library in MVC for client side templating.


9 Sep 2013

Getting Started with Mustache.js in MVC

In this post you will learn how to use Mustache.js JavaScript library in MVC for client side templating.  I will take you through few easy steps to setup it and working.

20 Aug 2013

Enabling Client Side Validation on Custom Data Annotations with IClientValidatable in MVC

In this post you will learn how to create or enable client side validation on the custom data annotations. If you go through my last blog, you will learn how to create custom data annotations to enable server side validation, I also recorded a video for this and uploaded on YouTube. This blog will take you further, so go and read or watch video, if you missed.

28 Jul 2013

Working with Azure BLOB Storage in MVC

In this post you will learn following things:

i) Introduction to BLOB Storage
ii) Installing the Azure SDK
iii) Creating MVC Application (Web Role) to upload BLOBs (for example, images) and delete BLOBs
iv) Publishing to Windows Azure (Storage and Web Role)

18 Jul 2013

Custom Data Annotations or Custom Validation Attributes in MVC: Video

In this video will learn how to create custom data annotation in MVC. MVC framework has great extensibility feature and because of this we can create our own customized data annotation attributes.

Globalization and Localization of Model Validation Message in MVC: Video

In this video you will learn how to globalize and localize the model validation message in MVC Applications. At the end, you will also learn how to display the localized message (greeting) on the web page.

15 Jul 2013

Custom Data Annotations or Custom Validation Attributes in MVC

In this post you will learn how to create custom data annotation in MVC. MVC framework has great extensibility feature and because of this we can create our own customized data annotation attributes.

13 Jul 2013

Globalization and Localization of Model Validation Message in MVC

In this quick post you will learn how to globalize and localize the model validation message in MVC Applications. At the end of this post, you will also learn how to display the localized message (greeting) on the page.

2 Jul 2013

Microsoft MVP: Honored to have received the Microsoft MVP award for the 2nd year


Do you know, 1st July has a very special meaning to me, this day starts with full of expectations which lasts until the moment of receiving email from Microsoft. Today, once again Microsoft awarded me with the MVP (Most Valuable Professional) award for the 2nd time in a row in the ASP.NET/IIS category.


I'm honored to be the part of Microsoft MVP Program, this is one of the most prestigious award and one of the great achievement of my life.

Here is the body of the mail that I received:

Dear Abhimanyu Kumar Vatsa,

Congratulations! We are pleased to present you with the 2013 Microsoft® MVP Award! This award is given to exceptional technical community leaders who actively share their high quality, real world expertise with others. We appreciate your outstanding contributions in ASP.NET/IIS technical communities during the past year.

I'd like to thanks to my all friends, family, community, blog readers and also like to send my special thanks to Shivprasad Koirala, Suprotim Agarwal, Kunal Chowdhury, Mahesh Chand for their continuous encouragements.

My very special thanks to Dhananjay Kumar (DJ), who is big brother to me and my mentor as well. I still remember his one of the thought "Microsoft MVP Award is not an Award rather it is a Responsibility that every MVP’s should follow".

I will give a special thanks to Microsoft India MVP Lead Biplab Paul and Tanmay Kapoor, for considering me.

Thanks.

20 Jun 2013

What are Default Model Binding and Explicit Model Binding in MVC?

Model Binding is a great feature we use today with Web Forms and MVC. In this post you will learn what are Default Model Binding and Explicit Model Binding in MVC. I will use few code snippets in this post so that you can understand it quickly.

17 Jun 2013

What is Eager Loading and what is Lazy Loading and what is N+1 Problem in Entity Framework

In this post you will learn what Eager Loading is and what Lazy Loading is and how this works in the application, and how you can take its advantages.

15 Jun 2013

Instant StyleCop Code Analysis How-to by Franck LEVEQUE - A Book Review

The very nice people at PACKT Publication recently asked me to write a review of their new book StyleCop Code Analysis, and you know I never miss the changes to learn things when it is for free J. Yes you heard it right, I received this book from publisher for free.

10 Jun 2013

View without Controller Action in MVC

In this quick post you will learn how a view can be rendered without its native Controller Action method.

What is Model and ViewModel in MVC Pattern?

Model and ViewModel are two things we always hear in MVC. And in this post I am going to show you the differences between them.

29 May 2013

Windows Authentication in MVC4 with IIS Express

MVC4 gone through some major changes in Windows Authentication functionality with IIS Express. In this article you will learn how to enable Windows Authentication in MVC4 Web Application on IIS Express, just follow the given steps.

27 May 2013

I Am Now The Published Author of Instant Razor View Engine How-To

I am happy to announce the release of my book ‘Instant Razor View Engine How-To’, published by PACKT; and now available at Amazon for purchase.

Click on the image to enlarge.



Like us on Facebook here: https://www.facebook.com/RazorViewEngine

10 May 2013

Three ways to populate selected value in DropDownList on Edit or Update views - MVC

I have been asked this question many times that ‘how to populate/activate selected value/item (which I selected while inserting/adding new record) in Edit/Update mode’. I’m going to address few possible approaches here.

22 Apr 2013

Visual Studio 2012 and .NET 4.5 Expert Development Cookbook - A Book Review

In this post you will find my review notes and links to purchase this book. I am feeling very proud to be the reviewer of this book and will recommend everyone to purchase it.

21 Apr 2013

Populate Selected Item in DropDownList in Edit Mode MVC

Within last few days I received many questions on this title, so I decided to address this by a new blog entry. I am going to show you the best possible way to achieve this using Code First approach. Here is what we are going to achieve.

18 Apr 2013

Nested Collection Models in MVC to Add Multiple Phone Numbers - Part 3

This is Part 3 of the article series. Actually, in this article series we were developing an MVC application that will allow adding multiple phone numbers using Nested Model concept. User will be able to add or remove (zero or more phone numbers, I need minimum two phone numbers for each employee) phone numbers for any single employee.

16 Apr 2013

Using Microsoft SQL Server Management Studio to connect SQL Azure databases

In this article you will learn how to connect SQL Azure database from SQL Server Management Studio.

12 Apr 2013

Nested Collection Models in MVC to Add Multiple Phone Numbers - Part 2

This is Part 2 of the article series. Actually, in this article series we were developing an MVC application that will allow adding multiple phone numbers using Nested Model Concept. User will be able to add or remove (zero or more phone numbers, I need minimum two phone numbers for each employee) phone numbers for any single employee.

10 Apr 2013

Nested Collection Models in MVC to Add Multiple Phone Numbers - Part 1

In this article series, you will learn how to create MVC application that will allow adding multiple phone numbers using Nested Model Concept. User will be able to add or remove (zero or more phone numbers, I need minimum two phone numbers for each employee) phone numbers for any single employee. Also in later posts, I will show you how to List, Edit, Delete record(s) in such nested (relational) models concept. Here is the first look of the concept.

22 Mar 2013

ASP.NET MVC Online Training by Abhimanyu Kumar Vatsa

12 Mar 2013

Area in MVC - giving a nice physical structure & dealing with template bug

In my last blog post I talked about ‘retrieving views from different folders in MVC’ and it works cool when we want view pages always inside Views folder (which is on the project root) but our requirement not ends here.

The new version "Area in MVC 5" is available here.

Retrieve Views from Different Folders in MVC

In this post you will learn how to retrieve the views which is inside another folder. For example a view which is inside folder Views|Application|General|Index.cshtml. How will you map it or use it from controller? Is this possible?

4 Mar 2013

Code First Approach & Database Migration & Server Side Validations & Client Side Validations in MVC4: Video in Hindi

In this video you will learn how to create simple Feedback Submission Form. In the journey, I will explain the use of Code First Approach and Code First Database Migrations and also Sever Side Validations and Client Side Validations to validation the data entered by the user.

Client Side Username Availability Checking in MVC

It is often required live ‘username’ checking on user registration page in web applications. Today I developed this for my one of the web application and would like to share that with you.

3 Mar 2013

Logging Errors with ELMAH (Error Logging Modules And Handlers) in MVC 4

ELMAH is an alternative to HMS (Health Monitoring System) for logging errors which is free and available under open-source which is created and managed by Atif Aziz. HMS was (was...why?) great (with few pains) because it has option to capture all events as well as errors. With HMS developers has to design the UI for viewing the log information but with ELMAH, you just need to hit a URL to view log information.

2 Mar 2013

Removing or Customizing View Engines in MVC

In this article you will learn how to remove or customize View Engines which is not being used by application.

Enable Password Resetting with Simple Membership in MVC 4

In this article you will learn how to enable password resetting (in case user forgot the password) with Simple Membership in MVC. User needs to type his username and system will check its existence, if found correct this will send an email containing dynamically generated URL with username and password reset token.

22 Feb 2013

Output Caching in MVC

In this article you will learn everything about ‘Output Caching in MVC’. I will take you by showing some real examples to make your view crystal clear.

19 Feb 2013

Best way to prevent Cross Site Request Forgery Attacks in MVC 4

In this article you will learn what CSRF is and best way to prevent such attacks. After a quick introduction about CSRF I will show you an example where attacker will change the profile information with one-click.

16 Feb 2013

Avoiding Cross-Site Scripting (XSS) Attacks with AntiXSS in MVC 4

In this article you will learn how to avoid XSS attacks in MVC Application with Microsoft’s AntiXSS library. I will show you a case where user will submit the malicious HTML markup with message and it will start displaying annoying alert. Then I will move on and show you how to prevent it with AntiXSS.

14 Feb 2013

jQuery UI Autocomplete with JSON in MVC 4

In the last post jQuery Ajax GET and POST calls to Controller's Method in MVC we saw an example on ‘GET call with parameter to Controller’s Method which will return JSON data’ (in case you missed, go and read that before continuing here), let me put the screenshot here.

11 Feb 2013

jQuery Ajax GET and POST calls to Controller's Method in MVC

In this blog post I am going to cover some really interesting stuff which is very useful today in web application developments. You will learn how to make jQuery Ajax GET and POST calls to controller methods.

10 Feb 2013

Ajax.ActionLink and Html.ActionLink in MVC

In this post you will learn use of Ajax.ActionLink helper and Html.ActionLink. I will compare both to show you how it is different. Okay, let’s begin with Html.ActionLink.

6 Feb 2013

Quick Search, Replace and Navigate in Visual Studio IDE (A Must Read Post)

I would call this post as Tips/Tricks post because this post contains information about Visual Studio IDE features. I can see large number of developers are not familiar with these features. So, I thought writing a blog post collecting searching, replacing and navigating tips which is vital to happy and productive.

Cascading DropDownList in ASP.NET MVC

In this blog post you will learn how to create cascading DropDownList in ASP.NET MVC. I will take you through step by step approach so, let’s begin.

3 Feb 2013

Custom Validation with IValidatableObject in MVC

In this post you will learn how to create a self validatable object using IValidatableObject to validate data in MVC.

DropDownList Helper Data Binding in MVC

In this post you will learn how to bind data to a DropDownList helper in MVC. We will try binding data to a DropDownList from a List<SelectListItem>, a List<Model> and also from a database.

30 Jan 2013

Building NerdDinner.com MVC Application: Videos

Hello Folks. The videos listed in this post are not mine, these are recorded by Microsoft people for the community. I hope this can be useful.

5 Jan 2013

Adding metatags on .cshtml pages in MVC

This quick post is a response to a question I received today on Facebook. Please follow the steps to add metatags on .cshtml pages:-

1 Jan 2013

Happy New Year - 2013


Hello Friends!

Happy New Year to all of you, may your new year be blessed with peace, love and joy. I’m sending you my heartfelt wishes with joy that never ends. It’s time to forget all the past and think ahead.