ASP.NET Core

1234
Creating a Web API in ASP.NET Core
RESTful services are quite common and popular these days. If you ever developed modern service-based applications using ASP.NET Web Forms and ASP.NET MVC, chances are you used a Web API to create REST services. No wonder ASP.NET Core also allows you to create a Web API. This article discusses how a Web API service can be created in ASP.NET Core. It then shows how the created service can be invoked from JavaScript code.
Posted On : 15 May 2017
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.
Posted On : 02 May 2017
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.
Posted On : 31 Mar 2017
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.
Posted On : 08 Mar 2017
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.
Posted On : 28 Feb 2017
Deploy ASP.NET Core Web Application to IIS in 5 Easy Steps
Once you finish developing your ASP.NET Core web application the next step would be to deploy it under the IIS. Although this process is quite similar to traditional ASP.NET Web Forms or MVC applications, there are a few things you need to be aware of. To that end this article explains how an ASP.NET Core web application can be deployed under IIS.
Posted On : 06 Feb 2017
Create Custom Exception Filter in ASP.NET Core
In my previous article I explained how errors in an ASP.NET Core web application can be dealt with using middleware. I also mentioned that time that you can also use exception filters to handle errors. In this article I will explain how to do just that. In ASP.NET MVC 5 you used the [HandleError] attribute and OnException() controller method to deal with exceptions that arise in the actions of a controller. In ASP.NET Core the process is bit different but the overall concept is still the same.
Posted On : 16 Jan 2017
Five Methods to Deal with Errors in ASP.NET Core
Error handling is a common practice in any real-world web application. In ASP.NET Web Forms you used certain events and custom error pages to deal with them. In ASP.NET MVC you used [HandleError] attribute, exception filters and custom error pages to deal with them. In ASP.NET Core you have a set of methods and, of course, exception filters at your disposal. In this article I will discuss five methods that are used in connection with error handling.
Posted On : 02 Jan 2017
ASP.NET Core - Old Solution Structure Vs. New Solution Structure
Recently one of the reader, who was quite new to ASP.NET Core, asked this question - "I am following your instructions to create a working example based on your article. After creating the project my solution explorer looks different than your screen shots. Why is so? Am I missing something?" In this short post I am explaining why you see two different solution structures in Visual Studio 2015.
Posted On : 06 Dec 2016
Consume ASP.NET Core Web API using HttpClient
In the previous article you learnt to consume a Web API created in ASP.NET Core using jQuery client. Although local clients are quite common in Ajax rich applications, many real-world situations require that you call a Web API from a different application. Thus the client application and the Web API application are different and you can't use JavaScript to call the Web API (due to default browser settings). Moreover, if you wish to call a Web API from a desktop application JavaScript is not an option. In such cases you can use HttpClient to call the Web API. This article tells you how.
Posted On : 14 Nov 2016
1234