You are on page 1of 1

Public Class Form1

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)


Handles Button1.Click
Dim weight As Double = TextBox1.Text
Dim length As Double = TextBox2.Text
Dim width As Double = TextBox3.Text
Dim height As Double = TextBox4.Text
Dim size As Double

size = length * width * height


If size > 100000 Then
Label6.Text = "Rejected: Too Large"
End If

If weight > 27 Then


Label6.Text = "Rejected: Too Heavy"
End If

If size > 100000 And weight > 27 Then


Label6.Text = "Rejected: Too Heavy and Too Large"
End If
If size < 100000 And weight < 27 Then
Label6.Text = "Able to send package"
End If
End Sub
End Class

You might also like