Today in this article we will see how to render razor view or partial view to string in Asp.net MVC. View or partial view contains generally html tags and razor syntax, if we can convert view into string using C# than we can pass string as a Json Result from controller to view(for Ajax call). Let’s see sample code.
We have many times scenario of converting Amount Numbers which are Rupees, Dollar, Pound, Euro or any currency into Words while we programmed. Today We will see the easiest logic of converting Amount numbers into words in C#,VB or Asp.net without using of any loop and recursive functionality.
I have faced A potentially dangerous request.form value was detected from the client error many times while working with CkEditor or by entering special character in Asp.net web forms and Asp.net MVC. Here I am explaining complete solutions step by step and also reason for this error.
This article will explain about static class and members of static class like static method and static variables . To access static method and static variables doesn’t need to create instance of it’s class . Let’s try to demonstrate by example .
Abstract class in C# acts as a base class. Abstract Class can not be instantiated and can only be derived by its child classes. The need of abstract class is to provide some basic functionality which is used by it’s child classes so they can override and share. Let’s take a look at member of abstract class and abstract method.
In C# many times we have used ref and out parameters. In this article we will compare ref and out with example and will try to find out difference between reference and out keywords in c# and will conclude which is best among ref vs out.