Attention: We are retiring the ASP.NET Community Blogs. Learn more >

Thoughts on .Net & Coding

.Net Articles, tutorials, reviews, code and more...

  • Implementing AutoPostBack in ASP.NET Core

    Those of you who worked with ASP.NET web forms will recollect that certain server controls such as DropDownList have a property called AutoPostBack. This property when set to true automatically submits the form to the server and raises some server side event. In modern web development people prefer to use Ajax over AutoPostBack but at times AutoPostBack is what you might need. To that end this article shows how AutoPostBack can be implemented in ASP.NET Core applications.

  • 7 Things to Know About SQL Server Distributed Caching in ASP.NET Core

    In an article I wrote some time ago, I explained the essentials of in-memory caching in ASP.NET Core. Although in-memory caching serves its purpose in many small applications, at times you need distributed cache rather than local in-memory cache. Consider a situation where a web farm is serving the requests. In this case you can't guarantee that the server storing the cache will serve all the requests. You may also want your cache to survive application restarts.

  • 10 things to know about in-memory caching in ASP.NET Core

    The primary purpose of any caching mechanism is to improve performance of an application. As an ASP.NET developer you are probably aware that ASP.NET web forms as well as ASP.NET MVC could used Cache object to cache application data. This was often called server side data caching and was available as an inbuilt feature of the framework. Although ASP.NET Core doesn't have Cache object as such, you can implement in-memory caching quite easily. This article shows you how.

  • Read the application's configuration in ASP.NET Core

    As an ASP.NET developer you always used web.config to store and retrieve the application's configuration information. ASP.NET Core uses a different configuration system that is more flexible and powerful than before. In this article you will learn the basics of storing and retrieving the configuration information from JSON and XML files. You will also learn to use DI to inject this information into controllers.

  • 7 Features of C# 7.0 Worth Knowing

    As you are aware of C# 7.0 and Visual Studio 2017 have been released. In this article I quickly take you through seven new features of the language that are worth knowing. I assume that you are familiar with C# 6.0 and hence I am not going into too much technical details of these features here. My aim is to quickly let you know of a few interesting features that can make your C# code more efficient and clear. Let's get going.

  • Offline installation of VS2017 in 4 Easy Steps

    By default the installation of Visual Studio 2017 is taken care by a web installer. That means you download only the required components over the web. Although this works quite well in many cases, at times you may want to install Visual Studio 2017 in offline manner. Some of the possibilities include unstable internet connection and installation on large number of machines of your organization. As of this writing there is no ISO image of the product that one can download. Luckily, there is a command line way to grab all the installation components that you need for an offline installation. So, let's see how to grab them in four easy steps.

  • Enable Response Compression in ASP.NET Core in 5 Easy Steps

    As an ASP.NET developer you are probably aware that IIS comes with its own compression module that can effectively compress the response content. This can dramatically reduce the network bytes giving good performance benefits. However, what if you aren't using IIS at all? Luckily, ASP.NET Core offers you a middleware that can compress the response content for you. In this article you will learn to configure the ASP.NET Core response compression middleware in your web application.