Skip to main content

Convert Rupees to Dollar & Dollar to Rupees value in VB.NET.

PROPERTIES:
Label1,Label2
Text(Empty)
Label3
TextEnter Number Of Amount
ComboBox1
TextSelect Currency
ItemsRupees
Dollar
CODEING:
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:

Comments