smchoudhury
Programmer
Hi Guys,
Can someone direct me on how can i automatically update my value when a user changes the combobox item. At the moment i have a button click when the user changes the combobox item and press the button the values get updated, everytime the combobox item get changed i have to repeat it click the button to update the value. I want something where automitically as soon as the combobox item selected the total value in the text box to change without clicking the button. So if a user changes the item slected from the combobox the values within the text box should changes accoding to combobox changes without a button event handler:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
If ComboBox1.SelectedItem = "Seafood" Then
TextBox1.Text = 3.5 * ComboBox2.SelectedItem
End If
End Sub
Thanks,
choudhmh
Can someone direct me on how can i automatically update my value when a user changes the combobox item. At the moment i have a button click when the user changes the combobox item and press the button the values get updated, everytime the combobox item get changed i have to repeat it click the button to update the value. I want something where automitically as soon as the combobox item selected the total value in the text box to change without clicking the button. So if a user changes the item slected from the combobox the values within the text box should changes accoding to combobox changes without a button event handler:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
If ComboBox1.SelectedItem = "Seafood" Then
TextBox1.Text = 3.5 * ComboBox2.SelectedItem
End If
End Sub
Thanks,
choudhmh