Quantcast
Channel: Programming Forums
Viewing all articles
Browse latest Browse all 51036

Getting Text To Appear Depending On Drop Down List Choice ?

$
0
0
As The Title Says I'm Such With Getting An Event To Occur Depending On The Item Selected In The Drop Down List.

Following Code Used:

Protected Sub DropDownList1_TextChanged(sender As Object, e As System.EventArgs) Handles DropDownList1.TextChanged
        If DropDownList1.Text = "super" Then
            TextBox1.Text = "john"
            TextBox1.Text.ToString()

        End If
      End Sub


Also Tried:

Protected Sub DropDownList1_SelectedIndexChanged(sender As Object, e As System.EventArgs) Handles DropDownList1.SelectedIndexChanged
       Dim selected As String = DropDownList1.SelectedItem.ToString

        If selected = "super" Then

            TextBox1.Text = "john"
            TextBox1.Text.ToString()
        End If
      End Sub



Tried Other Ways Also But Nothing Worked. Any Help Will Be Amazing.

Thanks

John

Viewing all articles
Browse latest Browse all 51036

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>