I am using this technique: http://stackoverflow.com/questions/2670327/is-there-a-way-to-hold-the-values-lost-in-postback
After it does the postback, how do I set which item is selected?
$(document).ready(function() {
if (document.getElementById("txtHidData").value != "")<br>
$("#country").val(document.getElementById("txtHidData").value);<br>
//or<br>
//$("#country")[0].selectedIndex = document.getElementById("txtHidData").value;<br>
Does not work either way, any help? Thanks.
EDIT:
$("#country").change(function() {
debugger
var _selected = $("#country option:selected").val();
document.getElementById("txtHidData").value = "";
document.getElementById("txtHidData").value = _selected;
// $("#txtHidData").value = _selected;
....