Search results

Getting Started with ASP.NET Core

19 Oct 2021 / 2 minutes to read


To get start with ASP.NET Core application, need to ensure the following software to be installed on the machine.

  • Visual Studio 2017
  • DotNet Core 2.0

Setup ASP.NET Core application with Essential JS 2 for ASP.NET Core

The following steps to create ASP.NET Core Application.

Step 1: Create ASP.NET Core Web Application with default template project in Visual Studio 2017.

Alt text

Step 2: Once your project created. We need to add Syncfusion EJ2 package into your application by using Nugget Package Manager.

Open the nuGet package manager.

Alt text

Install the Syncfusion.EJ2 package to the application

Alt text

After Installation complete this will included in the project. You can refer it from the Project Assembly Reference.

We need to install NewtonSoft.JSON as dependency since it Syncfusion.EJ2 dependent to NewtonSoft.JSON package.

Step 3: Open the _ViewImports.cshtml to import Syncfusion.EJ2 package.

Copied to clipboard
@addTagHelper *, Syncfusion.EJ2

Step 4: Add client side resource through CDN or local package in the layout page _Layout.cshtml.

Copied to clipboard
@* Syncfusion Essential JS 2 Scripts *@
<script src=""></script>

Step 5: Adding Script Manager in layout page _Layout.cshtml.

Copied to clipboard

Step 6: Add the below code to your Index.cshtml view page which is present under Views/Home folder, to initialize the lineargauge.

Render Default LinearGauge

This section explains how to render default lineargauge.

Copied to clipboard
public IActionResult Default()
return View();

Add the ejs-lineargauge tag like below code snippet to create the default lineargauge.

Copied to clipboard
@using Syncfusion.EJ2;

<ejs-lineargauge id="linear">

Add Gauge Title

You can add a title using title attribute to the linear gauge to provide quick information to the user.

Copied to clipboard
@using Syncfusion.EJ2;

<ejs-lineargauge id="linear" title="Temperature Measure">


You can set the range to the axis using minimum and maximum attributes for axis tag. Refer below code snippet to add the axis range to lineargauge.

Copied to clipboard
<ejs-lineargauge id="linear" orientation="Horizontal">
    <e-lineargauge-axis minimum="0" maximum="200">