Dropdown List in ASP.net

Posted by Bhupentiwari under ASP.NET on 6/26/2012 | Points: 10 | Views : 996 | Status : [Member] | Replies : 7
I have dropdown on the selection of dropdown item i m calculating some price. now the problem is whole page is geting postback evry time..and it is taking too much time also

plz provide some solution

Thanks n Regards
Bhupendra Tiwari



Responses

Posted by: Swaroopa on: 6/26/2012 [Member] Starter | Points: 25

Up
0
Down
Hi ,

Use Ajax update panel to avoid whole page post back.



Swaroopa

Bhupentiwari, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Bhupentiwari on: 6/26/2012 [Member] Starter | Points: 25

Up
0
Down
can u explain with an example ?[/ ]

Thanks n Regards
Bhupendra Tiwari

Bhupentiwari, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Johnbhatt on: 6/27/2012 [Member] Starter | Points: 25

Up
0
Down
If you are using PostBack = True, then Page will be Loaded once. But you can use this with Ajax.
By the way, Post code, we will try to find and suggest you a new code for you.

John Bhatt
Glad to Know, Free to Share.....
http://www.johnbhatt.com

Bhupentiwari, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Jawed_Akhtar786 on: 6/27/2012 [Member] Starter | Points: 25

Up
0
Down
1.Use ajax.Placed your dropdown into updat panle-
<asp:ScriptManager ID="ScriptManager1" runat="server">
</asp:ScriptManager>

<asp:UpdatePanel ID="updatepanel1" runat="server">
<ContentTemplate><asp:DropDownList ID="ddl" runat="server"></asp:DropDownList></ContentTemplate>
</asp:UpdatePanel>
2.You can use javascript also.


Bhupentiwari, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Ajay.Kalol on: 6/27/2012 [Member] Starter | Points: 25

Up
0
Down
if you are caclulation prise statically then Use JavaScript. and Make enablePostback="false" in DDL Property.

if not then use UpdatePanel

Ajay
ajaypatelfromsanthal.blogspot.in

Bhupentiwari, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Btrack124 on: 6/28/2012 [Member] Starter | Points: 25

Up
0
Down
You can acheive this using a UpdatePanel with Ajax
refer below link
http://ajax.net-tutorials.com/controls/updatepanel-control/

Thanks
http://www.alacraft.com.au/

Roland Masten

Bhupentiwari, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Ranjeet_8 on: 6/28/2012 [Member] [MVP] Gold | Points: 25

Up
0
Down
Hi ,

Use Java Script to avoid whole page post back.
eg:
http://www.codeproject.com/Articles/656/Using-JavaScript-to-handle-drop-down-list-selectio



Bhupentiwari, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response