|
rg = New Syncfusion.Windows.Forms.Gauge.RadialGauge()
rg.GaugeLabel = "350 / 50"
rg.MinimumValue = 0
rg.MaximumValue = 350
rg.MinorDifference = 5
rg.MajorDifference = 50
rg.Size = New Size(200, 200)
rg.EnableCustomNeedles = True
rg.MinorInnerLinesHeight = 0
rg.MinorTickMarkHeight = 0
rg.Ranges.Clear()
gridLayout1.Columns = 5
gridLayout1.Rows = 20
gridLayout1.SetParticipateInLayout(rg, True)
'Add RadialGauge Control
Me.Controls.Add(Me.rg) |
|
'Create instance of RadialGauge Control
Private rg As Syncfusion.Windows.Forms.Gauge.RadialGauge
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
Try
'initialize the Syncfusion RadialGauge Control
rg = New Syncfusion.Windows.Forms.Gauge.RadialGauge()
rg.GaugeLabel = "350 / 50"
rg.MinimumValue = 0
rg.MaximumValue = 350
rg.MinorDifference = 5
rg.MajorDifference = 50
rg.Size = New Size(200, 200)
rg.EnableCustomNeedles = True
rg.MinorInnerLinesHeight = 0
rg.MinorTickMarkHeight = 0
rg.Ranges.Clear()
Me.GridLayout1.Rows = 5
Me.GridLayout1.Columns = 20
Me.GridLayout1.SetParticipateInLayout(rg, True)
Me.Controls.Add(Me.rg)
|
|
'Set Row Count
gridControl1.RowCount = 5
'Set Column Count
gridControl1.ColCount = 4
'Set Row height
Me.gridControl1.RowHeightEntries.AddRange(New Syncfusion.Windows.Forms.Grid.GridRowHeight() {
New Syncfusion.Windows.Forms.Grid.GridRowHeight(0, 30),
New Syncfusion.Windows.Forms.Grid.GridRowHeight(1, 300),
New Syncfusion.Windows.Forms.Grid.GridRowHeight(2, 300),
New Syncfusion.Windows.Forms.Grid.GridRowHeight(3, 300),
New Syncfusion.Windows.Forms.Grid.GridRowHeight(4, 300),
New Syncfusion.Windows.Forms.Grid.GridRowHeight(5, 300)
})
'set Column Width
Me.gridControl1.ColWidthEntries.AddRange(New Syncfusion.Windows.Forms.Grid.GridColWidth() {
New Syncfusion.Windows.Forms.Grid.GridColWidth(0, 200),
New Syncfusion.Windows.Forms.Grid.GridColWidth(1, 300),
New Syncfusion.Windows.Forms.Grid.GridColWidth(2, 300),
New Syncfusion.Windows.Forms.Grid.GridColWidth(3, 300),
New Syncfusion.Windows.Forms.Grid.GridColWidth(4, 300)
})
'Set Column Header
gridControl1(0, 1).CellValue = "SETT2018/06"
gridControl1(0, 2).CellValue = "SETT2018/07"
gridControl1(0, 3).CellValue = "SETT2018/08"
gridControl1(0, 4).CellValue = "SETT2018/09"
'Set Row Header
gridControl1(1, 0).CellValue = "GRUPPO 1"
gridControl1(2, 0).CellValue = "GRUPPO 2"
gridControl1(3, 0).CellValue = "GRUPPO 3"
gridControl1(4, 0).CellValue = "GRUPPO 4"
gridControl1(5, 0).CellValue = "GRUPPO ---"
'Radial Gauge
rg = New Syncfusion.Windows.Forms.Gauge.RadialGauge()
rg.GaugeLabel = "350 / 50"
rg.MinimumValue = 0
rg.MaximumValue = 350
rg.MinorDifference = 5
rg.MajorDifference = 50
rg.Size = New Size(200, 200)
rg.EnableCustomNeedles = True
rg.MinorInnerLinesHeight = 0
rg.MinorTickMarkHeight = 0
rg.Ranges.Clear()
'Load Radial Gauge into Grid Control
For i As Integer = 1 To gridControl1.RowCount
For j As Integer = 1 To gridControl1.ColCount
'Set the GridControl CellType as Control
gridControl1(i, j).CellType = "Control"
'set the Radial Gauge control into Grid Cell
gridControl1(i, j).Control = rg
Next j
Next i |