There are some keywords in C# that are considered contextual keyword, in that these are not reserved keywords but provides specific meaning in the code.Technically you can use these keywords as an identifiers but you should avoid to doing this, since it could lead to confusion.
C# | Asp.Net | MVC | SQL Server | jQuery | Java Script | Angular | .Net Core | Microservices
You are here » Home » All posts
Monday, September 17, 2012
Saturday, September 15, 2012
Examine IL Using ildasm.exe
In .Net , source is compiled to an Intermediate Language called Common Intermediate Language. This IL is later compiled into native code at runtime, running in a virtual machine.
You can examine the IL of your application by a tool called IL Disassembler (ildasm.exe). You can find this tool (ildasm) in directory: C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin
Ildasm will show you three basic things of IL :-
- A list of all classes and methods in your assembly
- The contents of the assembly’s manifest
- IL code for any method implemented in the assembly.
Here’s an example of what is displayed in ildasm.
You can get more information from these sites-
Wednesday, June 27, 2012
C# Static Methods
Static methods
have no instances.
They are called with the type name, not an instance identifier i.e we have no need to create the instance of class to call the static methods.So they are slightly faster than instance methods.
The static methods use the static keyword somewhere in the method declaration signature, usually as the first keyword or the second keyword after public
The static methods use the static keyword somewhere in the method declaration signature, usually as the first keyword or the second keyword after public
Wednesday, June 13, 2012
Extension Methods in C#
In this post, we will take a look at what extension methods are and how to use them in C#. Extension methods are one of the best things that have been introduced in .Net framework in terms of readability. Extension methods are available from .Net framework 3.5.
Monday, June 11, 2012
Partial Classes and Methods
Partial Classes and Methods
C# 2.0 introduced partial types to allow class definitions to be split between several files. C# 3.0 extends the concept with partial methods, allowing method signatures to be declared but not implemented. This is ideal for use with code generation tools.
In this post , I will try to explain the basic rules of partial classes and methods and how simple it is to use partial methods.
Subscribe to:
Posts (Atom)