Specifically, I am trying to build the image on this
I am programming in C # .NET and design a graphic in Adobe XD and I can not pass the same to visual studio, keeping the style. Use nuget LiveCharts in WinForm (https://lvcharts.net/App/examples/v1/wf/Solid%20Gauge). Try to generate the graphic similar to the design made in Adobe but I do not get it (second image). I need someone to guide me to make the same graphic corresponding to the first image.
I have problems to assemble the graphic of image 1; change the color of the digits where the current value is displayed, tick etc.
I take this opportunity to consult, once I have debugged and loaded the .dll, the "black" image is displayed as seen in the image. It's my first project with C #. This component is then charged from WinCC, which is a SCADA software and it is shown with a black background and if I change the value it shows the bar but the background remains black (image 4 and 5).
using System;
using System.ComponentModel;
using System.Windows;
using System.Windows.Forms;
using System.Windows.Media;
namespace temperaturaRodamientos
{
public partial class UserControl1: UserControl
{
//[Description("evento")]
private double _valor = -10.0;
public double valorNormal = 55.0;
public double valorPrecaucion = 80.0;
public double valorPeligro = 90.0;
public double valorMaximoSensor = 127.0;
[Description("Valor actual temperatura"), Category("Data")]
public double valor{
get { return _valor; }
set
{
_valor = value;
solidGauge2.Value = _valor;
solidGauge2.BackColorTransparent = true;
if (_valor<=valorNormal) //verde
{
solidGauge2.ToColor = Color.FromRgb(11, 211, 1);
solidGauge2.FromColor = Color.FromRgb(11, 211, 1);
} else if (_valor >= valorNormal && _valor <= valorPeligro) //amarillo
{
solidGauge2.ToColor = Color.FromRgb(255, 250, 101);
solidGauge2.FromColor = Color.FromRgb(255, 250, 101);
}
else //rojo
{
solidGauge2.ToColor = Color.FromRgb(252, 141, 141);
solidGauge2.FromColor = Color.FromRgb(252, 141, 141);
} //fin if-else
} //fin set
}
public UserControl1(){
InitializeComponent();
solidGauge2.Value = valor;
solidGauge2.From = valor;
solidGauge2.To = valorMaximoSensor;
solidGauge2.Base.LabelsVisibility = Visibility.Hidden; //no muestra los valores min/max
solidGauge2.ToColor = Color.FromRgb(11, 211, 1);
solidGauge2.FromColor = Color.FromRgb(11, 211, 1);
} //fin contructor
} //fin clase
} //fin proyecto