What Is the Difference Between Properties and Fields in C#
In this article, we will learn about the difference between Properties and Fields in C#, and how to use them. Let's...
Different Techniques to Convert a Number Between Hexadecimal and Decimal in C#
Manipulating numerical data is fundamental to many applications. In some cases, we may need to convert numbers between different bases. This article explores different ways to convert a number between hexadecimal and decimal in C# while offering insights into the...
Different Ways to Validate an Uploaded File in ASP.Net Core
As developers, we often tend to oversee the security of our applications. Whether the user misclicks on the wrong file or purposely uploads a malicious one, we should always validate the input loaded through our application.Β In this article, we'll look at a few...
Code Maze Weekly #201
Issue #201 of the Code Maze weekly. Check out what's new this week and enjoy the read. .NET and C# Top Picks The Saga of .NET Core and ASP.NET Core [www.mobilize.net] Since the .NET Core term is fading away slowly, let's remember how it...
How to Get the Number of Files in a Folder With C#
In this article, we are going to see how to get the number of files in a folder. C# provides several methods to determine file counts within a folder, each tailored for specific use cases.Β A simple middleware that logs your request headers can go a long...
Different Ways to Get the First Record in Each Group With LINQ
In this article, we will explore different methods to get the first record in each group with LINQ. Grouping, searching, sorting, filtering,...
Different Ways to Run Background Tasks in ASP.NET Core
In this article, we'll explore different ways of running background tasks in ASP.NET Core applications without depending on external providers. [sc name="github" url="https://github.com/CodeMazeBlog/CodeMazeGuides/tree/main/aspnetcore-features/RunningBackgroundTasks"...
How To Use ArraySegment in C#
In this article, we will show how to use the ArraySegment<T> in C#. Arrays are one of the most fundamental collection...
How to Select Multiple Records Based on a List of IDs Using LINQ
In this article, we are going to explore how to select multiple records based on a list of IDs using LINQ. We will demonstrate two ways to do that, and we will investigate the cases in which each might be a better choice. [sc name="github"...