PROPERTIES:
CODEING:
| Label1,Label2 | |
| Text | (Empty) |
| Label3 | |
| Text | Enter Number Of Amount |
| ComboBox1 | |
| Text | Select Currency |
| Items | Rupees |
| Dollar | |
Public Class Form1
Private Sub ComboBox1_SelectedIndexChanged(sender As Object, e As EventArgs) Handles ComboBox1.SelectedIndexChanged, TextBox1.TextChanged
If ComboBox1.Text = "Rupee" Then
Label2.Text = "Rupee:" & TextBox1.Text
Label1.Text = "Dollar:" & CStr(Math.Round(Val(TextBox1.Text) / 64.28F, 2))
ElseIf ComboBox1.Text = "Dollar" Then
Label2.Text = "Dollar:" & TextBox1.Text
Label1.Text = "Rupee:" & CStr(Math.Round(Val(TextBox1.Text) * 64.28F, 2))
End If
End Sub
End Class
DESIGNING:Private Sub ComboBox1_SelectedIndexChanged(sender As Object, e As EventArgs) Handles ComboBox1.SelectedIndexChanged, TextBox1.TextChanged
If ComboBox1.Text = "Rupee" Then
Label2.Text = "Rupee:" & TextBox1.Text
Label1.Text = "Dollar:" & CStr(Math.Round(Val(TextBox1.Text) / 64.28F, 2))
ElseIf ComboBox1.Text = "Dollar" Then
Label2.Text = "Dollar:" & TextBox1.Text
Label1.Text = "Rupee:" & CStr(Math.Round(Val(TextBox1.Text) * 64.28F, 2))
End If
End Sub
End Class
Comments
Post a Comment