Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

asp.net, drop down

Posted on 2014-02-27
1
252 Views
Last Modified: 2014-03-14
how can I make the drop down using get method in code behind?

like i have a asp.net dropdown and when someone select something inside, it will use get method and show on url like default.aspx?id=selectedvalue

by the way, I also use ajax toolkit with update panel.
0
Comment
Question by:CoolDev2014
1 Comment
 
LVL 33

Accepted Solution

by:
Big Monty earned 500 total points
ID: 39895012
you could just add an onchange attribute to the dropdown and set the url there:

<asp:DropDownList ID="ddl" runat="server"
  onchange="document.location.href = 'default.asp?id=this.value;" >
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
Boost your ability to deliver ambitious and competitive web apps by choosing the right JavaScript framework to best suit your project’s needs.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question