Obtenha o valor selecionado no suspensão
var e = document.getElementById("ddlViewBy");
var strUser = e.value;
var e = document.getElementById("ddlViewBy");
var strUser = e.value;
Plain JavaScript:
===================
var e = document.getElementById("elementId");
var value = e.options[e.selectedIndex].value;
var text = e.options[e.selectedIndex].text;
---------------------------------------------------------
jQuery:
=======
$("#elementId :selected").text(); // The text content of the selected option
$("#elementId :selected").val(); // The value of the selected option