I am developing an application on LCD font makers. I just completed an work on drawing boxes where i have to place my fonts. now I need to add numeric updown control which should help me in increasing and decreasing the rows and columns in the grid.. can anyone help me resolving my problem.
my code is
Public Class Form1
Dim x As Integer = 16
Dim y As Integer = 144
Dim box(x, y) As PictureBox
#Region "Run time Load"
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
buildmap()
End Sub
#End Region
#Region "build grid"
Public Sub buildmap()
For row = 0 To x
For column = 0 To y
drawbox(row, column)
Next
Next
End Sub
#End Region
#Region "Draw"
Public Sub drawbox(ByVal row As Integer, ByVal column As Integer)
box(row, column) = New PictureBox
box(row, column).Size = New Point(8, 8)
box(row, column).BorderStyle = BorderStyle.FixedSingle
box(row, column).BackColor = Color.White
box(row, column).Location = New Point((box(row, column).Width * column), (box(row, column).Height * row))
Me.Controls.Add(box(row, column))
End Sub
#End Region
Output:
This will be my output screen where the numeric controls are used to increase and decrease the rows and column in the current form.
Thanks in advance
Anonymous User
09-Mar-2015