.net Archives - {coding}Sight https://codingsight.com/tag/net/ Blog for SQL Server DBAs and Developers Mon, 13 Mar 2023 12:45:57 +0000 en-US hourly 1 https://wordpress.org/?v=6.5.2 https://codingsight.com/wp-content/uploads/2021/10/cropped-Soсial_-Fb_180х180-1-32x32.png .net Archives - {coding}Sight https://codingsight.com/tag/net/ 32 32 LINQ in C#: A tutorial with Query Examples in LINQ to Objects https://codingsight.com/what-is-linq-in-c-sharp/ Thu, 22 Apr 2021 12:55:53 +0000 http://codingsight.com/?p=12808 Less is more – this is definitely true when it comes to object collections and LINQ queries. One of the most valuable advantages is the ability to write cleaner and more concise code, thus accomplishing more with fewer lines. The current article will introduce the basic understanding of LINQ technologies and present alternatives to the …

The post LINQ in C#: A tutorial with Query Examples in LINQ to Objects appeared first on {coding}Sight.

]]>
.NET – Tools for working with multithreading and asynchrony – Part 2 https://codingsight.com/net-tools-for-working-with-multithreading-and-asynchrony-part-2/ Sun, 14 Jul 2019 22:27:12 +0000 https://codingsight.com/?p=7421 This article comprises the second part of my speech at the multithreading meetup. You can have a look at the first part here. In the first part, I focused on the basic set of tools used to start a thread or a Task, the ways to track their state, and some additional neat things such …

The post .NET – Tools for working with multithreading and asynchrony – Part 2 appeared first on {coding}Sight.

]]>
.NET: Tools for working with multi-threading and asynchrony – Part 1 https://codingsight.com/net-tools-for-working-with-multi-threading-and-asynchrony-part-1/ Wed, 22 May 2019 22:28:24 +0000 https://codingsight.com/?p=7027 The need to do things in an asynchronous way – that is, dividing big tasks between multiple working units – was present long before the appearance of computers. However, when they did appear, this need became even more obvious. It is now 2019, and I’m writing this article on a laptop powered by an 8-core …

The post .NET: Tools for working with multi-threading and asynchrony – Part 1 appeared first on {coding}Sight.

]]>
New Features in Visual Studio 2019 https://codingsight.com/new-features-in-visual-studio-2019/ Tue, 30 Apr 2019 21:50:34 +0000 https://codingsight.com/?p=6782 Microsoft has recently released the preview version of Visual Studio 2019. Like all previous editions, the latest Visual Studio comes with lots of improvements and new features that are focused on faster execution, more productivity for developers and team collaboration. If you haven’t downloaded it yet, you can do it here for free: Visual Studio …

The post New Features in Visual Studio 2019 appeared first on {coding}Sight.

]]>
Resource Release in .NET Applications https://codingsight.com/resource-release-in-net-applications/ Fri, 01 Dec 2017 13:03:32 +0000 http://codingsight.com/?p=2840 In C#, there is one huge benefit, which is a drawback at the same time – an automatic garbage collection. With traditional desktop applications, this is great when a platform cleans up the whole garbage and releases memory. However, it is not always good for Web. When we develop a Web application, Web-requests are mainly …

The post Resource Release in .NET Applications appeared first on {coding}Sight.

]]>
Using Expressions to Filter Data of Database https://codingsight.com/using-expressions-to-filter-data-of-database/ Fri, 10 Nov 2017 12:36:04 +0000 http://codingsight.com/?p=2489 I would like to start with a description of the problem that I encountered. There are entities in the database that need to be displayed as tables on the UI. The Entity Framework is used to access the database. There are filters for these table columns. It is necessary to write a code to filter entities by parameters. …

The post Using Expressions to Filter Data of Database appeared first on {coding}Sight.

]]>
What dangers can the update of .Net 4.6.1 to .Net 4.6.2 hide? https://codingsight.com/what-dangers-can-update-of-dot-net-hide/ Wed, 08 Nov 2017 14:58:54 +0000 http://codingsight.com/?p=2665 In this article, I would like to share a solution of unexpected problem occurred in one of the projects I am currently working on. What dangers can the update of .Net 4.6.1 to .Net 4.6.2 hide? I thought that to avoid serious issues during the update to a minor version, it was enough to read …

The post What dangers can the update of .Net 4.6.1 to .Net 4.6.2 hide? appeared first on {coding}Sight.

]]>
Comparison of 6 Best Dependency Injection (DI) Inversion of Control (IoC) Containers https://codingsight.com/configuation-comparison-dependency-injection-containers/ Fri, 03 Nov 2017 20:41:24 +0000 http://codingsight.com/?p=2591 I have often questioned myself which IoC container would be suitable for this or that project best. Their performance is only one side of the coin. The other side of the coin is the simplicity and speed of learning. So, I decided to compare the following containers from this point of view: Autofac, Simple Injector, …

The post Comparison of 6 Best Dependency Injection (DI) Inversion of Control (IoC) Containers appeared first on {coding}Sight.

]]>
Another Way to Localize Application https://codingsight.com/another-way-to-localize-application/ Fri, 13 Oct 2017 11:34:08 +0000 http://codingsight.com/?p=2420 I would like to introduce a simple way to localize applications. I do not like the standard mechanism with resource assemblies for the following reasons: When receiving a value of a localized string in the code, I would like to rely on OOP and compiler prompts. It is very unpleasant to generate a project on …

The post Another Way to Localize Application appeared first on {coding}Sight.

]]>
Generic Repository Pattern in Entity Framework https://codingsight.com/entity-framework-antipattern-repository/ https://codingsight.com/entity-framework-antipattern-repository/#comments Thu, 07 Sep 2017 05:52:59 +0000 http://codingsight.com/?p=2164 A Repository mediates between the domain and data mapping layers, acting like an in-memory domain object collection. Client objects construct query specifications declaratively and submit them to Repository for satisfaction. Entity Framework provides us with the actual implementation of the Repository patterns: DbSet<T> and UnitOfWork: DbContext. I often see colleagues using in projects their own …

The post Generic Repository Pattern in Entity Framework appeared first on {coding}Sight.

]]>
https://codingsight.com/entity-framework-antipattern-repository/feed/ 2