Public Class Form1

Private Sub cmdmark_Click(sender As Object, e As EventArgs) Handles cmdmark.Click
    Dim intsum As Integer, intnum As Integer
    Dim inthighest As Integer
    Dim intlowest As Integer
    intnum = InputBox("Enter the mark")
    intsum = intnum + intsum
    intnum = InputBox("Enter the mark For subject 2")
    intsum = intnum + intsum
    intnum = InputBox("Enter the mark for subject 3")
    intsum = intnum + intsum

    Lbltotal.Text = "Total marks are" & intsum
    lblaverage.Text = "The average is" & intsum / 3

    If intnum > intlowest Then
        intlowest = intsum
    End If
    If intsum > inthighest Then
        inthighest = intsum

        Lbllowest.Text = "The lowest number is" & intnum
        Lblhighest.Text = "The highets number is" & intnum
    End If
End Sub

End Class

Recommended Answers

All 3 Replies

And the question is?

If you want help then I suggest you do more than just cry "Help" and post undocumented code without any explanation as to what you need help with. It may be obvious what the problem is but if you can't go to the effort of asking a proper question...

What the others said. Describe the problem and its symptoms/errors.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.