
function KeyDownHandler(btn)  
{       
    // process only the Enter key           
    if (event.keyCode == 13)       
    {           
        // cancel the default submit            
        event.returnValue = false; 
        event.cancel = true; 
        var obj = document.getElementById(btn);
        obj.click();             
    }   
}

  function dropdownRedirect(ddlId)
  {
                if (!ddlId) return;
                var list = document.getElementById(ddlId);
                if (!list || !list.selectedIndex) return;

                var myWin, gotoUrl;
                gotoUrl = list.options[list.selectedIndex].value;
                if(gotoUrl)
                {
                    var pos = gotoUrl.indexOf("rd:")

                    if (pos >= 0)
                    {
                        var opnW = gotoUrl.replace("rd:", "");
                        window.open(opnW,'Mela','');
                    } else {
                        if(list.form.target)myWin = parent[list.form.target];
                        else myWin = window;
                        if (!myWin) return true;
                        myWin.location = gotoUrl;
                    }
                }
                return false;
 }
