Using Static Anonymous Functions in C#
In this article, we'll review static anonymous functions, which were introduced in C# 9. To understand how they can improve our code, we should first have a look at non-static anonymous methods and lambda expressions. Let's see what happens, as far as memory...
Standard and Custom Numeric Format Strings in .NET
In this article, we will look at the different standard and custom numeric format strings in .NET. Additionally, we will look at the support for the numeric format strings. How often do you think about the abstractions you use...
Read and Write Windows Registry in C#
In this article, we will learn what Windows Registry is, how we can work with it in .NET Core, and how we can read and write Windows Registry in C#. After that, we will explore some advanced use cases of the Windows Registry. A brief introduction to to most...
How to Force Run .NET Application as Administrator
In this article, we will learn how to force run a .NET application as an Administrator. We will do that by modifying the application manifest file of our application to illustrate the whole process. If you like using MongoDB in your project, here's a way to...
How to Read a String From a .resx (Resource) File in C#
In this article, we are going to learn how to read a string from a .resx file. While doing this, we are also going to understand what is going on under the hood. Additionally, we will follow some of the best practices on how to manage resource files, and lastly, offer...
Dynamically Adding Rows on a Form in Razor Pages
In this article, we will delve into ASP.NET Core forms and how to add rows to them dynamically. We'll use razor pages to create the form and SQLite as our database. [sc name="github"...
How to Solve The type ‘TRequest’ Cannot be Used as Type Parameter in MediatR
When working with MediatR in .NET, we can often utilize its Pipeline Behavior. In this article, we'll examine a common warning related to the type TRequest that can occur while working with it, see why it appears, and how we can solve it. [sc name="github"...