Multiplication Table in VB.NET
Submitted by donbermoy on Tuesday, February 18, 2014 - 16:54.
Hi! this is me again! For now we will have to create a Multiplication Table using VB.NET.
So, now let's start this tutorial!
1. Let's start with creating a Windows Form Application for this tutorial by following the following steps in Microsoft Visual Studio: Go to File, click New Project, and choose Windows Application.
2. Next, add Three TextBoxes namely TextBox1 for entering the first number, TextBox2 for entering the number limit, and TextBox3 for the result of the Multiplication Table. You must design your layout like this:
3. Next, put this code in Button1_Click so that it will display the Multiplication table.
Download the source code below and try it! :)
For more inquiries and need programmer for your thesis systems in any kind of programming languages, just contact my number below.
Best Regards,

- Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
- Dim n1, n2, i As Integer
- For i = 1 To n2
- Dim a As Integer
- a = n1 * i
- TextBox3.Text = TextBox3.Text & n1 & " * " & i & " = " & a
- TextBox3.Text = TextBox3.Text & vbCrLf
- Next
- End Sub
Explanation:
We initializedn1, n2 as Integer
because we passed the value of our input in TextBox1 to n1 and TextBox2 to n2.
- For i = 1 To n2
- Dim a As Integer
- a = n1 * i
- TextBox3.Text = TextBox3.Text & n1 & " * " & i & " = " & a
- TextBox3.Text = TextBox3.Text & vbCrLf
- Next
For i = 1 To n2
- our variable i will start at 1 up to the n2 as we input it in TextBox2. Next, we initialized a as Integer to have the result of multiplication done in n1 up to the value of i which limits at n2. Then, TextBox3 will now have the value of n1*i = a. We use vbCrLf
to create a newline.
Now, input 8 in TextBox1 and 10 in TexBox2 then click the Button. It will have a multiplication table like the image below.

Engr. Lyndon R. Bermoy
IT Instructor/System Developer/Android Developer
Mobile: 09079373999
Telephone: 826-9296
E-mail:[email protected]
Visit and like my page on Facebook at: Bermz ISware Solutions
Subscribe at my YouTube Channel at: SerBermz
Comments
Add new comment
- Add new comment
- 12267 views