In this tutorial we'll see how to display the master records in a DropDownList control and the details of the selected list item in a GridView. I used update panel and Trigger with AsyncPostBackTrigger but I did not get success. Check out my previous article Using simple Drop Down Lists in ASP. Ive made a control with 2 textboxes and 1 dropdownlist. Form except CheckBoxList control. DropDownList Values getting cleared after PostBack in ASP. Download Code or Download PDF. For example, one of these find is that when the panel with the DropDownList. Rishitnandan. Maintain the dynamic control events, data during postback in asp. 0; Connected web parts - provider empty on postback when consumer; Web Part Provider Interface is null on every-other postback; Dropdownlist in Master Page; Populate dropdownlist from sql server 2000 database; DropDownList autofill behavior; DropDownList. Download Sample App or Download PDF. This makes Semantic UI dropdown useless in the ASP. Hi, All of you. If the user selects another value in the drop-down, I want the grid rows to reload (via callback), taking the user's selection into account (basically rebuilding the grid with a new DataSet). The Scaffolding method. Introduction In this article we will learn how to maintain the state of dynamically created controls in asp. auart has a value table. Controls are losing values on postback Hello I have two dropdowns in a gridview that need cascading functionality but I have experianced problems with the cascading drop down extenders in the past so I have decieded to write my own javascript. NET form elements. NET Forums on Bytes. Binding DropDownListFor from enum, database and some hard coded values in our previous article MVC dropdown binding best ways. When having a custom control that has some controls in it (e. When user hits Save, I do a postback and save these values into the database. Retain Dropdown Selected Value After Postback Javascript. Hi Fever, Thanks for using syncfusion products, Query: Dropdown list how to show data to index 0 instead value empty We would like to let you know that we have provided a property called “selectedItemIndex” which is used to specify which item value to be displayed in the dropdown list. Programming Languages I have a webgrid with dropdownlist and onchange it postback the page. How to get a drop down list with the selected value across the Post back. Looks like viewstate does not keep the actual values in the dropdownlist if the datasource table values change (get wiped out in my case) when the page is posted back. Dropdownlist not keeping viewstate after postback - ASP. Any pointers?. Net; DropDownList Values getting cleared after PostBack in ASP. To remove the flicker from the page, I placed my drop down list in an update panel, but now it does not postback. by Christian Wenz. Here Mudassar Ahmed Khan has explained with an example, the difference between AutoPostBack True and AutoPostBack False in ASP. I'll cover the following topics in the code samples below: DropDownListPage, EventArgs, ArrayList, Class, and Ajax Asynchronous Javascript. How can I make dropdownlist no postback - I have a dropdownlist which I put a code in selected indexchanged - basically for every indexchanged the code will connect to sql and get values then populate textboxes with values. Enable/Disable ASP. Maintain the dynamic control events, data during postback in asp. UserControl values lost on PostBack - ASP. the browser only sends back the selected value to the server. If the runtime sees a value it doesn’t know about, it throws an exception. NET Forums on Bytes. and what about a dynamically created requiredfieldvalidator for a dynamically created textbox or dropdownlist in a webUserControl(. Return Value: A String, representing the value of the value attribute of an element in the drop-down list. Selecting items from listbox without postback i have a listbox which shows some categories in a listbox and a checkbox list for each of the selected categ. NET Building Controls. net projects. It is easy to get posted values after postback by the help of Request. This will show you how you can use a use dropdown list inside an MVC webgrid. the filtering is working fine but on every postback the dropdown list seleted value is reset to default value. This first time could be on Init or LoadViewState phases of the page lifecycle. NET AJAX Grid. Description: One of the common annoying problem that developer face while creating Asp. But when I enter values in them and get a postback the values are gone. When click in any tab and click in any autopostback control, the DropDownList in ftab are load again and lost the selected value. Then dropdownlist control will not get bind on all post_back events and the selected item by user will be there. If you use: ddlInfo. Creating forms for the web is one of them. LockScreenAfterDDLChange(DropDownList, message) - much like LockScreenAfterClick, this method locks the screen after the passed-in DropDownList control has been changed on the client-side. ddlState is in update panel. If the runtime sees a value it doesn’t know about, it throws an exception. NET Forums on Bytes. And there is no code in my html page or code behind where I clear the value of Hidden1. Selecting items from listbox without postback i have a listbox which shows some categories in a listbox and a checkbox list for each of the selected categ. In this tutorial we'll see how to display the master records in a DropDownList control and the details of the selected list item in a GridView. How to load the dropdownlist box without postback? eg: if you choose country in one dropdown the corresponding states wil fetch in another dropdo. Family values and contentment Your speed will fall from 60 to 1 and your car's horsepower will drop down from 250 to 5. As there could be multiple drop down lists in the same form, first we need to select the drop down list uniquely and get the value using the val function of jQuery. Dropdownlist selected value lost after postback. Solution walkthrough. Hence, I used CONDENSE on the key before appending the values to the drop down list internal table which was later passed on to function module 'VRM_SET_VALUES'. I also have a server side button object but I hook up javascript to it to show a modal dialog. Please help me. Hello, Am facing this peculiar problem with a dropdownlist in the Gridview. Problem retaining values of dropdownlist controls after postback. I have been struggling with this for over a week and posted in a few forums - to no avail. and what about a dynamically created requiredfieldvalidator for a dynamically created textbox or dropdownlist in a webUserControl(. How do I save value in gridview after postback without using database. NET Forums on Bytes. Last Reply on Nov 14, 2016 09:43 AM By dharmendr. Yii postback value for dropdownlist. DropDownList, it's name property is the same as your model's property name, you pass a SelectList with you selected value, but in the UI it's not showing your expected selection. In a grid I put a dropdownlist with autopostback=true the items where just static (1,2,3-10). Say this is my GridView bound to a SqlDataSource that get’s the products details. But on PostBack, the DropDownList controls have lost all the ListItem options not even the SelectedValue! any items and since the selected value is based on. Handling Postbacks from a ModalPopup (C#) 06/02/2008; 2 minutes to read +1; In this article. net MVC, C#. TextBox), the value in that controls is lost on postback of the page. Hi, All of you. Get each value of Dropdownlist in Gridview after Postback So i have here a dropddownlist inside a gridview. Hi All, I have a server runnable textbox control. Answered Active Solved. Introduction In this article we will learn how to maintain the state of dynamically created controls in asp. Is Postback and Is Not Postback Could someone please explain to me what they are and when to use them. Create a Table in SQL Server. Tags: postback, repeater, viewstate trackback. please help to achive the requirement. While the new option is added to the dropdownlist, if the dropdownlist is set to AutoPostback=true and has a script to run OnSelectedIndexChanged the dropdownlist resets and the value suddenly no longer exists. net mvc3 how to keep dropdown list selected item after postback. it is not a good idea. Steve's solution involves the addition of a simple server control in the Web Form, a technique that works in a myriad of browsers. Here Mudassar Ahmed Khan has provided solution to the problem where value of the TextBox placed in GridView is lost after PostBack in ASP. Return Value: A String, representing the value of the value attribute of an element in the drop-down list. ValueType property value. NET application we are all familiar with DropDown but as we moved to MVC we lost our favorite ASP. Jim_Stanley. But it doing postback but I don't want postback. Ask Question. Select only the header row and the data, if you include the filter row it won't work. Two dropdownlists are one is ddlcountry and another one is ddlstates. While the new option is added to the dropdownlist, if the dropdownlist is set to AutoPostback=true and has a script to run OnSelectedIndexChanged the dropdownlist resets and the value suddenly no longer exists. The SelectedIndexChanged the 1st DropDown is always called on postback and so it throws "populateDdl()" at every PostBack (if a value is selected). C# - Possible To Re-DataBind A DropDownList Upon Postback Triggered By SelectedIndexChanged Event? Feb 3, 2011. Then the control will lose its data binding on any post back actions. If the drop-down list allows multiple selections, the first selected option is returned. This raises a couple issues because we may not know all of the legal values the control can take. If you don't want to do a postback on adding every and each hobby, you can either: - use a session variable to store the edited user's state and add the hobbies with an ajax call - use a multiselect listbox instead of dropdowns. When the page first loads, the drop-down will have a default value, and the grid will be populated based on the default value. I can click the drop down and the list will be there. Use the DropDownList control to create a single-selection drop-down list Gets or sets a value indicating whether a postback to the server automatically occurs. I work mostly on intranet stuff so not only I know that JS is enabled, what browser they are using (and what version), even what their default screen resolution is. The Parameters. Recent posts by Ankit Bhatt. Get each value of Dropdownlist in Gridview after Postback So i have here a dropddownlist inside a gridview. NET TextBox Control (for example), and it's READONLY or DISABLED, the postback won't catch the changed value. Retain the state of dynamic created controls or maintain the data of dynamic created/ added user control on postback in asp. This works fine, but now the users want another drop down box to be added and filled with different options depending on what they pick from the first drop down box. Maintain State For ASP. Net DropDownList using JavaScript and jQuery. Controls are losing values on postback Hello I have two dropdowns in a gridview that need cascading functionality but I have experianced problems with the cascading drop down extenders in the past so I have decieded to write my own javascript. I want the drop down box to be on a different worksheet. But, the grid doesnot persist data when coming into the click event - it is losing its state on postback. Answered Active Solved. But, currently our Dropdownlist control behavior is, during the postback, the value in the Dropdownlist textbox alone is obtained. Net with C# and VB. Gets or sets a value indicating whether a postback to the server automatically occurs when the user changes the list selection. Problem in gridview in link button:Invalid postback or callback argument coming based on the value selected in the first dropdown list. Hi, Im trying to make my own web custom control. by Christian Wenz. When I select value in DropDownList AjaxFileUpload lose the value. Invalid postback or callback argument. net dropdownlist control. Hi, I have a dropdownlist in side a gridview, Onselectedindexchanged I want to some action. keep selected value after postback dropdown list Jun 23, 2011 05:06 AM | lvbasanta | LINK I have many dropdownlist binded to a datasource that is used to save items to a database, everythinng works, but when i save the items to the database i want to keep the last selected value of my dropdown to make more inserts with the same values. In this article I will discuss more about handling dropdownlist in the postback of the ASP. On selection of country i have populated its states using selectedindexchanged event of ddlCountry. Postbacks are commonly seen in edit forms, where the user introduces information in a form, hits "save" or "submit", causing a postback. DropDownList selected value lost on postback This is causing the page to reload which causes the ddl to lose its selected value. If you use: ddlInfo. On PostBack however (the ListItemCollections are not re-generated on postback) the ListItems in the dropdownlist contain the. When I select value in DropDownList AjaxFileUpload lose the value. I am working on ASP. 6m developers to have your questions answered on RadAjaxManager losing drop down list value after Ajax postback of UI for ASP. (The DropDownList is only populated when the page is not postback) Help please. Is there some other way to have the lists on one sheet, get unique values and sort them, then reference them from a drop down on another worksheet?. Download Code or Download PDF. This article will also help us to deploy the custom field on the server. If, say, the script was programmed to only accept capital letters, then a drop-down menu would secure that no invalid entries were made. AddItemInList() function adds a new ListItem into the DropDownList based from the values entered from the TextBox Control. NET AJAX Ajax. Problem with dropdownlist in a webpart You also need to set them on every postback. Do I use them when I'm updating a page 30-Jul-19 1. how to retain value of dropdown list after postback which is extended by ajax cascading dropdownlist extendar. Hi, Can you further elaborate your problem? your retain value is for nxt drop down list? how many drop down list you have?. Minimal working example is below:. Load on demand works fine, but when i select an item that's further in the list, the selection is lost after a postback and jumps to the first visible item in the list. Net C# without creating a web service. NET MVC Today, we go from a beginner of SELECT tags to the mastery of DropDownLists, ListBoxes, and other types of lists in your MVC Views. But, currently our Dropdownlist control behavior is, during the postback, the value in the Dropdownlist textbox alone is obtained. JavaScript – How to recover the value of a selected option in a dropdown list. In day to day life in programming we make use of Properties to pass data from Page to Web User Control and vice versa in asp. I am using AjaxFileUpload for upload multiple files. The page on_load event loads the default value of each dropdown box. NET Building Controls. Is Postback and Is Not Postback Could someone please explain to me what they are and when to use them. I am working on ASP. How can I do this with the inverted OnInit phase? I have it filling the list, but its losing its selected value on postback. The following sections explain how to get the values on the post back in these controls. As I noted, since the DropDownList does not provide updated values upon postback of a form, I use the ASP. Dynamic Controls Lost On Postback. The drop down choices are given in SharePoint, so that is where the options are coming from. ValueType property value. net with c# which dynamically generates 6 textboxes, 2 dropdownlist box and 2 buttons. AJAX TabContainer - losing ListBox data on postback. Is there a workaround for this behaviour? I use netadvantage v2010. Dropdownlist selected value lost after postback. I want the drop down box to be on a different worksheet. This tutorial will explain how to use asp. keep the value of a dropdown after postback. There are cases in which you may want to trigger postback/ajax request to the server when the user clicks a grid data row anywhere (not only when hitting a button/checkbox/other control in the row). net dropdownlist control. i have ddlCountry dropdownlist and ddlState dropdownlist. Selecting items from listbox without postback i have a listbox which shows some categories in a listbox and a checkbox list for each of the selected categ. I have a HTMLEditorExtender on my page and when I try to access the. In this article I will describe after binding data or values from an XML file to a DropDownList when we will select a particular item in the DropDownList it will display the selected item without any post back to the server. 6m developers to have your questions answered on SelectedValue lost on postback in dynamically added user controls of UI for ASP. NET TextBox Control (for example), and it's READONLY or DISABLED, the postback won't catch the changed value. How to load the dropdownlist box without postback? eg: if you choose country in one dropdown the corresponding states wil fetch in another dropdo. Answered Active Solved. In the above code a dynamic label is created to show some gap between newly created dropdownlist. I can click the drop down and the list will be there. Retaining drop down list box value of a form after posting From a drop down list box or combo box visitor selects one option and submits the form. Reset DropDownList selected value on PostBack using jQuery. I have a HTMLEditorExtender on my page and when I try to access the. Rate this: dropdownlist losing value on postback. In the Page_Load I fetch the value of the _EVENTTARGET variable which in this case is the ID of the DropDownList. Unfortunately, on my home PC that has Windows 7 and IE 8 installed, the drop-down menus just do not work (they do on my office PC that has XP Professional and IE 7). Thanks for the code & tutorial, needed to use ajax on a page, which had a drop down list, of companies and people. Here is some example code for overriding the render method (in VB and C#) and declaring a potential value for the dropdownlist ddCar. Not sure if anyone every had this problem but my custom aspx page loses all the value and text when I hit the asp submit button. In the gridview, I got a dropdown list for each line that pre-selects an option depending on the DB value for that. I used VRM_SET_VALUES and VRM_GET_VALUES for populating the values from the programand not use any domain level value table for. If the runtime sees a value it doesn’t know about, it throws an exception. How to get a drop down list with the selected value across the Post back. Net C# without creating a web service. Inside an update panel I have two dropdownlists. Dropdownlist does not keep value when postback JQuery - Losing Drop down and textbox value on postback Textbox Losing its Value after Postback on Repeater_ItemCommand. NET Forums on Bytes. Using Auto-Postback with CascadingDropDown (C#) 06/02/2008; 2 minutes to read +1; In this article. In day to day life in programming we make use of Properties to pass data from Page to Web User Control and vice versa in asp. But it doing postback but I don't want postback. NET AJAX ComboBox. I am working on ASP. For the demo, you can use the Employee Details table, which I have created before. In this way the Product dropdownlist is populated and no Page PostBack happens. In a page I have a link; clicking on it opens a dialog and sets a textbox value for that dialog. ColumnName <<< This line. Net DropDownList using JavaScript and jQuery. Last Reply on Nov 14, 2016 09:43 AM By dharmendr. To remove the flicker from the page, I placed my drop down list in an update panel, but now it does not postback. Dropdownlist control allows user to select only single item at a time. BSP view losing selected value from dropdown list box the information or the structure and field have nothing to do in your code and that´s why you lose the value. A postback is an HTTP POST to the same page that the form is on. net - Dropdownlist Is Cleared On Page Postback; Remain Index Of Dropdownlist After Postback? Asp. You can create the EJ form controls, and define the form method as post and also define the respective action for the form. DropDownList selected value lost on postback This is causing the page to reload which causes the ddl to lose its selected value. Losing Textbox Value On Postback? Jun 9, 2010. But on form I have one DropDownList with AutoPostBack=true. Answered Active Solved. i have ddlCountry dropdownlist and ddlState dropdownlist. Hi All, I have a server runnable textbox control. Hello: I am currently using WebDataGrid version 10. Dropdownlist not keeping viewstate after postback - ASP. Last Reply on Nov 14, 2016 09:43 AM By dharmendr. NET controls, sometimes after a partial page postback, the functionality suddenly stops working. Hi, Can you further elaborate your problem? your retain value is for nxt drop down list? how many drop down list you have?. hello, I want to ask how to keep the value selected in the dropdown list (within a search filter) when I navigate in the pages of the search results (using the pager), because I am losing the filter values on navigation, for example: after filtering products to choose only Laptops, and navigating to the second page of the search results, the products refresh and remove the condition. AJAX TabContainer - losing ListBox data on postback. There are options like using AJAX callbacks on selectedIndex change of dropdownlist but sometimes it is needed that you postback the entire form and render it again. I used VRM_SET_VALUES and VRM_GET_VALUES for populating the values from the programand not use any domain level value table for. If the user selects another value in the drop-down, I want the grid rows to reload (via callback), taking the user's selection into account (basically rebuilding the grid with a new DataSet). Now, DropDownList will look at the provided default selected value and displays it. So, I see that the issue is present when assigning a value to the textbox through client-side code but not when its value is set through server-side code. Dropdownlist does not keep value when postback JQuery - Losing Drop down and textbox value on postback Textbox Losing its Value after Postback on Repeater_ItemCommand. To understand, here all my code : Aspx code:. I also have a server side button object but I hook up javascript to it to show a modal dialog. Keeping in mind what we stated above, we know that we can recover the index, the value or text. The Request object. Set Selected Value for DropdownList on Clientside using Javascript May 29, 2010 collecteddotnet 3 Comments Sometimes we need show the dropdownlist control with some selected value after some activity ( without server postback ) on the web page. All, I've been banging my head against the wall for hours now, and my co-workers don't have an. Retain Dropdown Selected Value After Postback Javascript. Download Sample App or Download PDF. dropdownlist ClearSelection() method clears out the list selection and set the selected property of all items to false. I am building a composite server control that currently only has a TextBox and a DropDownList. Problem: You're using the Html. DropDownList is not retaining selected index on PostBack I am going to try and map my flow out and explain as best as possible. The dropdownlist is loaded with crmservice. Hi, Im trying to make my own web custom control. However , when I clicked on one of the values in the drop down , the page submitted and reloaded but the script (above) was missing in the new page(). net application. Here Mudassar Ahmed Khan has provided solution to a problem where the selected value of the jQuery DatePicker TextBox is lost after PostBack in ASP. One of my more reliable defenders, even though he did lose his place in the side a couple of times for inconsistent form, and he is 31 years old now, the truth is that Teddy has always been a. As a result I pay the price of fetching the values each time from the DB upon postback. how to retain value of dropdown list after postback which is extended by ajax cascading dropdownlist extendar. Then dropdownlist control will not get bind on all post_back events and the selected item by user will be there. cannot get value of dropdownlist from postback. NET AJAX Ajax. How to load the dropdownlist box without postback? eg: if you choose country in one dropdown the corresponding states wil fetch in another dropdo. The Scaffolding method. Form loads with the correct value in the textbox, and the dropdown optiosn populated, but the selected value is lost. Postback occurs due to another event on the form. It is easy to get posted values after postback by the help of Request. I am populating a dropdownlist based on the selection from another dorpdownlist. hello, I want to ask how to keep the value selected in the dropdown list (within a search filter) when I navigate in the pages of the search results (using the pager), because I am losing the filter values on navigation, for example: after filtering products to choose only Laptops, and navigating to the second page of the search results, the products refresh and remove the condition. Problem with dropdownlist in a webpart You also need to set them on every postback. But when I enter values in them and get a postback the values are gone. In this article we will examine how to add dynamic Web controls to a page in such a manner that you will not need to worry about losing form field values on postback. But each postback clears any text field data input or selected. I have created a JSP page and i placed a dropDownList on. net - DropDownList After Postback All Values/index Lost. When there is a asp:DropDownList element with property AutoPostBack=true, a postback is triggered upon initializing the dropdown. Get each value of Dropdownlist in Gridview after Postback So i have here a dropddownlist inside a gridview. It seems like my 2nd DropDown is bounded on every postback even if it's not because of SelectedIndexChanged of my 1st DropDown. Introduction In this article we will see how to use the DropDownList control in ASP. got many similar pages that work, but this page is losing the selection each time I submit the form, and I don't know why. DropDownList Values getting cleared after PostBack in ASP. If you're concerned with reloading data over and over, no worries, Kentico. All, I've been banging my head against the wall for hours now, and my co-workers don't have an. On selection of country i have populated its states using selectedindexchanged event of ddlCountry. How To Make DropdownList No Postback Sep 12, 2011. In the Page_Load I fetch the value of the _EVENTTARGET variable which in this case is the ID of the DropDownList. Invalid postback or callback argument. Gets or sets a value indicating whether a postback to the server automatically occurs when the user changes the list selection. Hi all, I have a very simple user control that contains 3 drop downs. Here Mudassar Ahmed Khan has provided solution to a problem where the selected value of the jQuery DatePicker TextBox is lost after PostBack in ASP. 2) If the attribute is present I checked if it has some value which the user entered/selected before postback. DropDownList Within Composite Control Is Losing Selected Value On Postback Feb 23, 2010 I am building a composite server control that currently only has a TextBox and a DropDownList. hi, How can I make dropdownlist no postback - I have a dropdownlist which I put a code in selected indexchanged -basically for every indexchanged the code will connect to sql and get values then populate textboxes with values. This property can use viewstate to store its value rather than a member variable that would lose the value over a postback. I can click the drop down and the list will be there. get or set a value that indicate whether a postback to the server automatically occurs when the user changes the list selection. The dropdown list populates with the relevant values and I am able to select a particluar item from the dropdown list without any postback issues etc, I am also able to grab the selected value when doing a postback or where I have some javascript/ajax function that is trying to workout if the user has selected something. Reset DropDownList selected value on PostBack using jQuery. Due to performance reasons, I've turned off the Page's ViewState. Add values to asp:DropDownList (VB. postback the DropDownList box is losing the values. the value of the ID will change on every postback. In both cases I first clicked Button1 to set the textbox's value to "1" and then clicked Button2 to perform a postback. Datatable Reload Without Postback. This is the time when the new autopostback-on-row-click feature of Telerik RadGrid comes handy. hello, I want to ask how to keep the value selected in the dropdown list (within a search filter) when I navigate in the pages of the search results (using the pager), because I am losing the filter values on navigation, for example: after filtering products to choose only Laptops, and navigating to the second page of the search results, the products refresh and remove the condition. We need a DropDownList control for our demo. C# DropDownList selecting a value. Try putting your car in reverse gear. The drop down choices are given in SharePoint, so that is where the options are coming from. 5 and have the following problem: My database has to keep track of doctoral students' extra-curricular activities. Hence, I used CONDENSE on the key before appending the values to the drop down list internal table which was later passed on to function module 'VRM_SET_VALUES'. Net Ajax to develop this custom field. But each postback clears any text field data input or selected. But i want to maintain whatever password i have entered in the textbox across postback. Using Auto-Postback with CascadingDropDown (C#) 06/02/2008; 2 minutes to read +1; In this article. Ask Question. When I select a value in the dropdownlist I get a postback and the value I selected is selected even after the postback. NET DropDownList. I also have a server side button object but I hook up javascript to it to show a modal dialog. Hai all,I am face the problem with dropdownlist value inside gridview. I have a ListView (with nested controls including LinkButtons) and a data pager that is bound to a data source that loads items (Cases) in a user control (. protected int NumberOfControls { get { return (int)ViewState["NumControls"]; }. 6m developers to have your questions answered on Radcombobox not retaining selected value after postback of UI for ASP. I can get the dropdown loaded but after postback it is empty. This tutorial will explain how to use asp. DropDownList Within Composite Control Is Losing Selected Value On Postback Feb 23, 2010 I am building a composite server control that currently only has a TextBox and a DropDownList. Another thing I ran into If you're using an ASP. net using c#. The pre-populated values on the page load is missing from the control. In this article we will examine how to add dynamic Web controls to a page in such a manner that you will not need to worry about losing form field values on postback. This property can use viewstate to store its value rather than a member variable that would lose the value over a postback. I can click the drop down and the list will be there. (The DropDownList is only populated when the page is not postback) Help please. I have created a JSP page and i placed a dropDownList on. Founds lots of similar problems in forums but can't find anything that works for me. how to retain value of dropdown list after postback which is extended by ajax cascading dropdownlist extendar. it is called only on postback, not on. In above code, I’m checking what the selected value was using LINQ query and then using that value inside SelectList. In a grid I put a dropdownlist with autopostback=true the items where just static (1,2,3-10). Reset DropDownList selected value on PostBack using jQuery. The problem is that on postback the system only gives me values for combo boxes that were changed by the user. Net; DropDownList Values getting cleared after PostBack in ASP. Here I will explain how to use jQuery to set dropdownlist selected value or text based on value / text or jQuery set dropdownlist value based on value or text with example.