Category: C#
How to List out only Even Numbers from a List of Integers using Lambda Expression in C#?
Below is sample code snippet that demonstrates how to list out only even numbers from a list of integers using Lambda Expression in C#. How to List out only Even Numbers from a List of Integers using Lambda Expression in C#?
Rules for using Anonymous Types in C#
The anonymous types (var) in C# is an interesting feature that the C# developers could use within their .NET application . When using the anonymous type , there are certain criteria or rules that needs to be followed . Rules for using Anonymous Types in C# Below are some of the rules that the developers should be following when using the anonymous type. 1. NULL…
C# Compiler Error – CS0404 cannot apply attribute class ‘{0}’ becau
In this blog post, you’ll learn more about the C# Compiler Error – CS0404 and the related message description C# Compiler Error Code CS0404 C# Compiler Description for the Code :CS0404 Cannot apply attribute class ‘{0}’ because it is generic
C# Compiler Error – CS1677 parameter {0} should not be declared wit
In this blog post, you’ll learn more about the C# Compiler Error – CS1677 and the related message description C# Compiler Error Code CS1677 C# Compiler Description for the Code :CS1677 Parameter {0} should not be declared with the ‘{1}’ keyword
C# Compiler Error – CS8852 init-only property or indexer ‘{0}’ can
In this blog post, you’ll learn more about the C# Compiler Error – CS8852 and the related message description C# Compiler Error Code CS8852 C# Compiler Description for the Code :CS8852 Init-only property or indexer ‘{0}’ can only be assigned in an object initializer, or on ‘this’ or ‘base’ in an instance constructor or an ‘init’ accessor.
How to prevent the class from being inherited in C#?
How can one prevent the class from being inherited by another class using c#? It’s simple, mark the class as “sealed”. How to prevent the class from being inherited in C#?
C# Compiler Error – CS8789 the type of a local declared in a fixed
In this blog post, you’ll learn more about the C# Compiler Error – CS8789 and the related message description C# Compiler Error Code CS8789 C# Compiler Description for the Code :CS8789 The type of a local declared in a fixed statement cannot be a function pointer type.
C# Compiler Error – CS8858 the receiver type ‘{0}’ is not a valid r
In this blog post, you’ll learn more about the C# Compiler Error – CS8858 and the related message description C# Compiler Error Code CS8858 C# Compiler Description for the Code :CS8858 The receiver type ‘{0}’ is not a valid record type and is not a struct type.
C# Compiler Error – CS0729 type ‘{0}’ is defined in this assembly,
In this blog post, you’ll learn more about the C# Compiler Error – CS0729 and the related message description C# Compiler Error Code CS0729 C# Compiler Description for the Code :CS0729 Type ‘{0}’ is defined in this assembly, but a type forwarder is specified for it
C# Compiler Error – CS8147 properties which return by reference can
In this blog post, you’ll learn more about the C# Compiler Error – CS8147 and the related message description C# Compiler Error Code CS8147 C# Compiler Description for the Code :CS8147 Properties which return by reference cannot have set accessors
C# Compiler Warning – CS8767 nullability of reference types in type o
In this blog post, you’ll learn more about the C# Compiler Warning – CS8767 and the related message description C# Compiler Warning Code CS8767 C# Compiler Description for the Code :CS8767 Nullability of reference types in type of parameter ‘{0}’ of ‘{1}’ doesn’t match implicitly implemented member ‘{2}’ (possibly because of nullability attributes).
C# Compiler Error – CS8787 cannot convert method group to function
In this blog post, you’ll learn more about the C# Compiler Error – CS8787 and the related message description C# Compiler Error Code CS8787 C# Compiler Description for the Code :CS8787 Cannot convert method group to function pointer (Are you missing a ‘&’?)
C# Compiler Error – CS0558 user-defined operator ‘{0}’ must be decl
In this blog post, you’ll learn more about the C# Compiler Error – CS0558 and the related message description C# Compiler Error Code CS0558 C# Compiler Description for the Code :CS0558 User-defined operator ‘{0}’ must be declared static and public
C# Compiler Warning – CS3011 ‘{0}’: only cls-compliant members can be
In this blog post, you’ll learn more about the C# Compiler Warning – CS3011 and the related message description C# Compiler Warning Code CS3011 C# Compiler Description for the Code :CS3011 ‘{0}’: only CLS-compliant members can be abstract
C# Compiler Error – CS8796 partial method ‘{0}’ must have accessibi
In this blog post, you’ll learn more about the C# Compiler Error – CS8796 and the related message description C# Compiler Error Code CS8796 C# Compiler Description for the Code :CS8796 Partial method ‘{0}’ must have accessibility modifiers because it has a non-void return type.
C# Compiler Error – CS8802 only one compilation unit can have top-l
In this blog post, you’ll learn more about the C# Compiler Error – CS8802 and the related message description C# Compiler Error Code CS8802 C# Compiler Description for the Code :CS8802 Only one compilation unit can have top-level statements.
How to Set the Windows Phone 8 icons in Visual Studio 2012?
You can set the icons for your Windows Phone 8 app in Visual Studio 2012 using the WMAppManifest.xml manifest file. The Visual Studio 2012 includes a GUI editor for editing WMAppManifest.xml manifest file. How to Set the Windows Phone 8 icons in Visual Studio 2012? You can find the WMAppManifest.xml, under the properties node of the project in the Visual Studio solution explorer. Just double…
C# Compiler Warning – CS0028 ‘{0}’ has the wrong signature to be an e
In this blog post, you’ll learn more about the C# Compiler Warning – CS0028 and the related message description C# Compiler Warning Code CS0028 C# Compiler Description for the Code :CS0028 ‘{0}’ has the wrong signature to be an entry point
C# Compiler Error – CS0450 ‘{0}’: cannot specify both a constraint
In this blog post, you’ll learn more about the C# Compiler Error – CS0450 and the related message description C# Compiler Error Code CS0450 C# Compiler Description for the Code :CS0450 ‘{0}’: cannot specify both a constraint class and the ‘class’ or ‘struct’ constraint
C# Compiler Error – CS1524 expected catch or finally
In this blog post, you’ll learn more about the C# Compiler Error – CS1524 and the related message description C# Compiler Error Code CS1524 C# Compiler Description for the Code :CS1524 Expected catch or finally