Search results

Internationalization in ASP.NET Core Circular Gauge control

22 Sep 2021 / 1 minute to read

Circular gauge provide supports for internationalization for below gauge elements.

  • Axis label.
  • Tooltip.

For more information about number formatter you can refer internationalization.

Globalization

Globalization is the process of designing and developing a component that works in different cultures/locales. Internationalization library is used to globalize number in CircularGauge component using format property in labelStyle.

Numeric Format

In the below example axis labels are globalized to EUR.

tagHelper
internationalization.cs
Copied to clipboard
@using Syncfusion.EJ2;

<div id="container">
    <ejs-circulargauge id="circular" locale="de">
        <e-circulargauge-axes>
            <e-circulargauge-axis>
                <e-axis-labelstyle format="c"></e-axis-labelstyle>
            </e-circulargauge-axis>
        </e-circulargauge-axes>
    </ejs-circulargauge>
</div>
<script>
    ej.base.setCulture('de');
    ej.base.setCurrencyCode('EUR');
</script>
Copied to clipboard
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Mvc;
using EJ2_Core_Application.Models;
using Newtonsoft.Json;

namespace EJ2_Core_Application.Controllers
{
    public class HomeController : Controller
    {
        public IActionResult Index()
        {
            return View();
        }
    }
}