469,322 Members | 1,579 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,322 developers. It's quick & easy.

dropdownlist selectedvalue (url open new window)

I would like to open a new window to a url that I have set as the dropdownlist.selectedvalue on the selected index change event. The selectedvalue is the url path and it will open in the existing window. I've tried window.open before the url, but that doesn't work.

protected void DropDownList_SelectedIndexChanged(object sender, EventArgs e)
Mar 29 '07 #1
1 4558
try onchange in the select option
<select name="somevalue" id="somevalue" onchange="newpage(this);">

in javascript:
var x=document.getelementbyid("somevalue");
window.open('page.ddl.x.item(x.selectedIndex).valu e')
or use this if u want in same window
Apr 2 '07 #2

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

reply views Thread by Daniel Doyle | last post: by
reply views Thread by zhoujie | last post: by
reply views Thread by mdpf | last post: by
reply views Thread by harlem98 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.