Option Explicit
Private Sub Command1_Click()
Dim n As String
n = Text1.Text
MsgBox ("voters name is:-" & UCase(n))
End Sub
Private Sub Command2_Click()
Dim age As String
age = Text2.Text
If IsNumeric(age) = True Then
If age > 18 Then
MsgBox ("voters age is:- " & age)
End If
Else
MsgBox ("you are entered string:- " & age)
End If
End Sub
Private Sub Command3_Click()
Dim ind, n As String
n = india
ind = Text3.Text
If ind = india Then
MsgBox ("Voters nationality is:- " & ind)
Else
MsgBox ("voters nationality is other country:-" & ind)
End If
End Sub
Private Sub Command4_Click()
Dim name, ind As String
Dim age As Integer
name = Text1.Text
age = Val(Text2.Text)
ind = Text3.Text
MsgBox ("Voters details is:-" & " " & name & " " & " " & age & " " & ind)
End Sub