Abundant Code

  • C#
  • C++
  • Elastic Search
  • Entity Framework
  • F#
  • JavaScript
  • ASP.NET
  • C
  • Java
  • SQL Server
  • Assembly Lang
Home ยป C#

How to Remove Duplicates in List using LINQ?

November 28, 2020 by AbundantCode Leave a Comment

There are times when you have to remove duplicate entried from a List from Your C# program and one of the easiest way to do that is using the combination of the LINQ and IEqualityComparer interface. Assume that you have a list of Actors as shown below ID : 1 , Name = Vijay ,Language […]

Filed Under: C# Tagged With: duplicate, Duplicates, LINQ

How to Get the File Size in C# ?

November 28, 2020 by AbundantCode Leave a Comment

If you need a way to get the size of a file in your C# program , you can use the Length property of the FileInfo class. How to Get the File Size in C# ? FileInfo.Length returns the length of the file in bytes.

Filed Under: C# Tagged With: File Size

How to get last four characters from a string in C#?

November 27, 2020 by AbundantCode Leave a Comment

This post will provide a simple tip showing how you can get the last 4 characters from a string in C#. How to get last four characters from a string in C#? Assume that you have a string that contains the value “CodersEditor.com” and you wish to get .com from the string and display it. […]

Filed Under: C# Tagged With: C#, string

How to Skip Iteration of a foreach loop in C# ?

November 26, 2020 by AbundantCode Leave a Comment

When using C# programming language , there are times when you might want to skip over the iteration based on some condition and jump over to the next iteration. How to Skip Iteration of a foreach loop in C# ? continue keyword comes to your rescue for this use case. When you want to skip […]

Filed Under: C# Tagged With: C#, loop

How to Calculate MD5 checksum for a file in C# ?

November 21, 2020 by AbundantCode Leave a Comment

There are times when you want to calculate MD5 checksum for a file in C# and you can easily do that using System.Security.Cryptography.MD5 You can use the ComputeHash method of the MD5 instance by passing the stream. You can later it to Hex using the BitConverter so that you can represent it as string for […]

Filed Under: C# Tagged With: C#, MD5

What is the best data type for Currency in C#?

November 9, 2020 by AbundantCode Leave a Comment

If you are looking at finding out what could be the best data type for currency in C# ?, this post will provide a quick tip or insights on the same. What is the best data type for Currency in C#? Use decimal for any currency or money values. The decimal keyword indicates a 128-bit […]

Filed Under: C# Tagged With: Currency datatype, Money datatype

C# Program – How to Escape Braces ?

September 10, 2020 by AbundantCode Leave a Comment

This post shows you a quick way on how you can escape braces or curly brackets in C# when using string format.

Filed Under: C# Tagged With: c# tips, escape braces

C# Program – Generate Random Alphanumeric String

September 10, 2020 by AbundantCode Leave a Comment

This post explains how you can generate a random alphanumeric string in C#.

Filed Under: C# Tagged With: random alphanumeric string, random string

C# Program – Multiline string literal in C#

August 28, 2020 by AbundantCode Leave a Comment

If you are looking at an easy way to create a multiline string literal in C#, then you use the verbatim string literal as shown in the below code snippet. C# Program – Multiline string literal in C# Using the verbatim stting ensures that it allows multiple lunes and also you donot need to have […]

Filed Under: C# Tagged With: multiline string, Verbatim String

C# – How to Call the base constructor ?

August 26, 2020 by AbundantCode Leave a Comment

In C#, You can call the base constructor using the base keyword as shown below. How to Call the base constructor in C# ?

Filed Under: C# Tagged With: inheritence

  • 1
  • 2
  • 3
  • …
  • 53
  • Next Page »
RSS
Facebook
fb-share-icon
Twitter
Visit Us
Follow Me
Tweet

Recent Posts

  • Collapsible links for subcategories in Docusaurus Sidebar
  • Python Program to Print Fibonacci Series
  • Python Program to Generate Multiplication Table
  • Python Program to Find the Factorial of a Number
  • Python Program to Print Prime Numbers in a Given Interval

Categories

Tags

.NET App Array ASP.NET ASP.NET MVC Assembly Language C# C# programs c lab programs Collection convert C program csharp database Example F# guide How to How to in Java integer Java Javascript Lab programs Lambda LINQ List Python lab programs Python programs SIC/XE SQL Server string tips tricks tutorial tutorials UWP visual studio 2015 Windows Windows 8 Windows 10 Windows Phone Windows Phone 8 Windows Phone 8.1 wp8 XAML

Blog Stats

  • 8,729,431 hits

Archives

Top Posts & Pages

  • C Program to Multiply Two Matrices Using Multi-dimensional Arrays
  • How to open display settings from command line in Windows 10 ?
  • How to Convert a Stream to Byte Array in C# 4.0 ?
  • C Program to display half-pyramid using alphabets
  • How to Extract number from a string using C# ?
  • Json.NET & VB.NET - How to Deserialize an Object ?
  • System Software - SIC/XE Program to clear 20 byte string to empty
  • How to Check if Integer is a multiple of a number in Java?
  • Tools to Convert Java to C# Source Code
  • How to Allow only numeric input in a Textbox in WPF ?

Categories

  • Android
  • Angular 2
  • ASP.NET
  • Assembly Language
  • C
  • C#
  • C++
  • Elastic Search
  • Entity Framework
  • Excel
  • F#
  • HTML
  • Interview Questions
  • Java
  • JavaScript
  • jQuery
  • Microsoft Office
  • MySQL
  • NETWORK
  • News
  • PHP
  • popular
  • PowerShell
  • Python
  • Ruby
  • SharePoint
  • SQL Server
  • SQL Server
  • Unix
  • VB.NET
  • Visual Studio
  • WebAPI
  • Windows
  • Windows Azure
  • Windows Forms
  • XAML

Top Posts & Pages

  • C Program to Multiply Two Matrices Using Multi-dimensional Arrays
  • How to open display settings from command line in Windows 10 ?
  • How to Convert a Stream to Byte Array in C# 4.0 ?
  • C Program to display half-pyramid using alphabets
  • How to Extract number from a string using C# ?
  • Json.NET & VB.NET - How to Deserialize an Object ?
  • System Software - SIC/XE Program to clear 20 byte string to empty
  • How to Check if Integer is a multiple of a number in Java?
  • Tools to Convert Java to C# Source Code
  • How to Allow only numeric input in a Textbox in WPF ?

Recent Posts

  • Collapsible links for subcategories in Docusaurus Sidebar
  • Python Program to Print Fibonacci Series
  • Python Program to Generate Multiplication Table
  • Python Program to Find the Factorial of a Number
  • Python Program to Print Prime Numbers in a Given Interval
  • Python Program to Check Prime Number
  • Python Program to Find the Largest Value Among Three Numbers
  • Python Program to Check If a Given Year is Leap Year
  • Python Program to Check if a Number is Odd or Even
  • Python Program to Check if a Number is Positive, Negative or Zero

Tags

.NET App Array ASP.NET ASP.NET MVC Assembly Language C# C# programs c lab programs Collection convert C program csharp database Example F# guide How to How to in Java integer Java Javascript Lab programs Lambda LINQ List Python lab programs Python programs SIC/XE SQL Server string tips tricks tutorial tutorials UWP visual studio 2015 Windows Windows 8 Windows 10 Windows Phone Windows Phone 8 Windows Phone 8.1 wp8 XAML