私には 5 つの値があり、それらを比較して、どの値が最大であるかに応じて何らかのアクションを実行しようとしています。
値は v1、v2、v3、v4、および v5 です。
If (v1 > v2 And v1 > v3 And v1 > v4 And v1 > v5) Then
l1st.Text = "Al-Haj Shaji Gul"
Label5.ForeColor = Color.Red
Me.PictureBox12.Image = Global.shaji.My.Resources.Resources.shajismal
ElseIf (v2 > v3 And v2 > v4 And v2 > v1 And v2 > v5) Then
l1st.Text = "Nor huq"
Label6.ForeColor = Color.Red
Me.PictureBox12.Image = Global.shaji.My.Resources.Resources.norlhuq
ElseIf (v3 > v1 And v3 > v2 And v2 > v4 And v3 > v5) Then
l1st.Text = "Darya Khan"
Label7.ForeColor = Color.Red
Me.PictureBox12.Image = Global.shaji.My.Resources.Resources.daryakhanpic
ElseIf (v4 > v1 And v4 > v2 And v4 > v3 And v4 > v5) Then
l1st.Text = "Imran Khan"
Label8.ForeColor = Color.Red
Me.PictureBox12.Image = Global.shaji.My.Resources.Resources.Imran_Khan
ElseIf (v5 > v1 And v5 > v2 And v5 > v3 And v5 > v4) Then
l1st.Text = "Zarnoor Afridi"
Label10.ForeColor = Color.Red
Me.PictureBox12.Image = Global.shaji.My.Resources.Resources.zarnorsmal
End If