Constructors in C# with demo
Constructors in C sharp The syntax for declaring basic constructors is a method that has the same name as the containing class and that does not have any return type: public class Student { public Student() { } //other class definition It’s not necessary to provide a...
strongly typed html helpers in asp.net mvc razor
Strongly typed html helpers are introduced in MVC 2. In this kind of helpers we can generate html markup or view using model properties and lambda expression. These methods use a "Html.HelperNameFor()” naming convention. for example we have created model property like...
automapper in Csharp with example
AutoMapper in C# AutoMapper is utility package provided by the Microsoft net framework. Automapper provides mapping between one class object to another class object. In simple words assigning properties values of one class into another class is called automapping. You...
Inline HtmlHelpers in asp.net MVC 5
The @helper syntax within Razor enables you to easily create re-usable helper methods that can encapsulate output functionality within your view templates. They enable better code reuse, and can also facilitate more readable code. Example1 : step1. Create Controller...