I have a web page that contains a drop-down list, a text box and a button. I set drop-down list and text box AutoPostBack property as false. When I run this page, I selected something in the drop-down list, and type some text in text box, then hit "Submit" button. I expected the result will base on what I selected and what i type in the textbox. However, it is not!
When i traced the code, I selected "PO #" in the drop-down list and I typed "12345" in TextBox2 then I hit "Submit" button. However, the following code:
Expand|Select|Wrap|Line Numbers
- If DropDownList1.SelectedItem.Text = "PO #" And TextBox2.Text <> "" Then
- op_po = 1
- Else
- op_po = 0
- End If
Anyone got an idea how to resolve this?