Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1037011
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T14:47:54+00:00 2026-05-16T14:47:54+00:00

I have two drop down list on a page. The first one list projects

  • 0

I have two drop down list on a page. The first one list projects and the second list users.

The userlist is populated with an object datasourse that pulls a list of users for the selected Project.

Whenever the Project list selection changes the second ddl Userlist always reverts to the first person in the list instead the person that was selected before a new Project was chosen.

I want to be able to select a new project and not have the selected person in the UserList change.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T14:47:54+00:00Added an answer on May 16, 2026 at 2:47 pm

    You’ll need to store the Id of the user that is currently selected before you do you databinding. One way would be to handle SelectedIndexChanged on your Project ddl so that you can grab the user id of the selected item in your User ddl then do the binding manually. Once the binding is done, then you can attempt to set the SelectedValue of the ddl to the User Id you had stored.

    EDIT: Added an example:

    In your aspx:

    <asp:DropDownList ID="projectddl" runat="server" AutoPostBack="true" OnSelectedIndexChanged="projectddl_SelectedIndexChanged">
        <asp:ListItem Text="Project 1" Value="1" />
        <asp:ListItem Text="Project 2" Value="2" />
        <asp:ListItem Text="Project 3" Value="3" />
    </asp:DropDownList>
    
        <asp:DropDownList ID="usersddl" runat="server">
        </asp:DropDownList>
    

    In your code-behind:

    protected void projectddl_SelectedIndexChanged(object sender, EventArgs e)
    {
        string currentlySelectedUserId = usersddl.SelectedValue;
    
        // Do your user databinding here based on project selected
    
        usersddl.SelectedValue = currentlySelectedUserId;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have one drop down list in my page, which contains two options. What
I have two drop down lists. Second one is populated based on value chosen
i have two dropdown list. first drop down:1 enter code here <form:select path=custName id=custName>
I have two Drop Down Lists, the second ones are based off which one
lets say i have two drop down list and one button on my search
I have two drop down list in my webpage and one is dependent on
I have a drop down list and some styles applied to it from two
I have two search buttons on a page, one linked to a dropdown list
I have a drop down list with two values (for now..) with other elements
I have two drop down lists on a page. The behavior is as follows:

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.