Wednesday, August 27, 2014

Let Vs Into Keywords in LINQ

Let Vs Into Keywords in LINQ This article shows two keywords of LINQ. These keywords are very helpful when working with a set of object collections using LINQ. First I will go through the Into keyword and its use. I used the following collection in this article, on which I've done actions in this article. 1: List<Mobile> objMobileCollection...

Tuesday, August 26, 2014

Difference between IEnumerable and IEnumerator

Difference between IEnumerable and IEnumerator Hi Geeks,     Here are few points which I learnt about IEnumerable and IEnumerator. IEnumerable uses IEnumerator internally. IEnumerable doesnt know which item/object is executing. Whenever we pass IEnumerator to another function ,it knows the current position of item/object. Whenever we...

Friday, August 22, 2014

Difference between prop and attr in JQuery.

Difference between prop and attr in JQuery?Answer: JQuery.attr()Get the value of an attribute for the first element in the set of matched elements.Whereas:JQuery. Prop ()Gets the value of a property for the first element in the set of matched elements. What Attributes actually areAttributes carry additional information about an HTML element and come...

Tuesday, August 12, 2014

Cross-Site Scripting Attack in MVC4

Cross-Site Scripting Attack in MVC4     In this article we will explore Cross-Site Scripting in an MVC application. In general this is the most dangerous threat by hackers. Cross-Site Scripting is a kind of security feat. An attacker inserts malicious code into a web page or a storage database. XSS in itself is a threat that is brought...

Monday, August 11, 2014

Validation failed for one or more entities. See EntityValidationErrors property for more details. Today I encountered an error during data insertion through Entity Framework as per the Title. There could be a various cause of such issue .Here I am talking about one of them.In database I restricted Name column data Type to nvarchar(10). and I was...

Friday, August 8, 2014

Difference/Similarities BETWEEN HTML.RENDERACTION AND HTML.ACTION   Html.RenderAction() and Html.Action()  are action helper methods in ASP.NET MVC. Generally both methods are used for calling action methods or child action methods  and rendering the result of action method in view. @Html.Action() – Invokes the specified child action...

Thursday, August 7, 2014

The RouteData must contain an item named "action" with a non-empty string value Hi Folks, Since I am exploring MVC these days I have tried to temper MVC with given functionality and encountered an error. I think we should understand why it comes and what exactly is wrong with our code.Errors Value cannot be null or empty. Parameter name: controllerName...

Wednesday, August 6, 2014

Child Action Methods in ASP.NET MVC4

Child Action Methods in ASP.NET MVC4     In this article we will explore Child Action method which is accessible at View level. In general each public method in a controller class is an action method. There could be multiple scenarios when we want to display some dynamic information (data) on pages. Child action is helpful in those scenarios....