public CircularProgressBar() { Size = new Size(130, 130); Font = new Font("Segoe UI", 15); MinimumSize = new Size(100, 100); DoubleBuffered = true; Value = 57; ProgressShape = _ProgressShape.Flat; this.ForeColor = Color.DimGray; }
public void RunProgress() { Width = 50; Height = 50; Visible = true; Value = 20; ProgressShape = CircularProgressBar._ProgressShape.Flat; var i = 0; var j = 0; Maximum = 100; var b = false; while (0 != 1) { if (i <= 100 && !b) { i++; j = 0; Value = i; } else { b = true; j++; i = 0; Value = 100 - j; if (Value == 0) { b = false; } } Update(); Application.DoEvents(); Thread.Sleep(20); } }