|
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
Postbacks without JavaScript?This is a discussion on Postbacks without JavaScript? within the JavaScript and Java forums. Topic: Hello, A search of the forums didn't find me quite what I was looking for, but my question is, ... |
![]() |
![]() |
|
![]() |
LinkBack | Thread Tools | ![]() | Search this Thread | ![]() | Display Modes | ![]() |
|
|
#1 (permalink) |
|
Hello,
A search of the forums didn't find me quite what I was looking for, but my question is, is it possible to do a postback to the same page in ASP.NET without using JavaScript? I'm building a "contact us" form, with different options available via dropdowns, and when someone chooses a dropdown, I want certain information and options on the page to change according to what they have chose (and if they decide to pick something else, I want it to change again, accordingly). I'm trying to avoid using client-side JS as much as possible because of the problems that occur if users have JS disabled, etc... Could someone point me in the right general direction for this? I don't even know if it's possible. I've tried Googling around for examples, but the ones I've found so far all use JS to do what I'm trying to do. Thanks, Kolyn_Kryw _________________ Singles Cheap auto loans |
|
|
|
|
|
|
#2 (permalink) |
|
Easy, if you're using the DropDownList control. Set AutoPostBack="true" on your DropDownList and handle the OnSelectedIndexChangedEvent.
<asp:DropDownList ID="_ddlItem" runat="server" AutoPostBack="true" OnSelectedIndexChanged="_ddlItem_SelectedIndexChan ged"> </asp:DropDownList> Last edited by jwright : 08-27-2008 at 04:27 PM. Reason: misspelling. :) |
|
|
|
|