In my ASP page, the list box is not pertaining the value in postback. How I can solve this using AJAX. Thanks in advance for your helo. Very urgent.
ASP and AJAX
Collapse
X
-
You don't need to use AJAX to retain the value of a listbox in postback.
Try this..
[Code=html]
<select name="sListBox" >
<option value="whatever 1" <% If Request.form("s ListBox") = "whatever1" Then Response.Write "SELECTED" End If %>> whatever1 </option>
<option value="whatever 2" <% If Request.form("s ListBox") = "whatever2" Then Response.Write "SELECTED" End If %>> whatever2 </option>
<option value="whatever 3" <% If Request.form("s ListBox") = "whatever3" Then Response.Write "SELECTED" End If %>> whatever3 </option>
</select>
[/code]
Sincerely,
Mark
Comment