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 8961209
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T15:50:06+00:00 2026-06-15T15:50:06+00:00

On selection of any radiobuttons or form events that trigger a post-back my radiobuttonlist

  • 0

On selection of any radiobuttons or form events that trigger a post-back my radiobuttonlist selections goto Index 0. None of the other form items are affected. I have disabled Master List redirect code, I have made an entirely new page with nothing in it except a dropdownlist, radiobuttonlist, and labels to view selected data. I am stumped.

Any advise? I just want it to keep the selectedindex and allow me to populate the correct value between post backs.

    <%@ Page Title="" Language="VB" MasterPageFile="~/MasterPage.master" AutoEventWireup="false" CodeFile="Default.aspx.vb" Inherits="s_Default" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder_menuBar" Runat="Server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="ContentPlaceHolder_userBar" Runat="Server">
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="ContentPlaceHolder_mainActivityWindow" Runat="Server">
<form id="Form1" runat="server">
    <p>
        <asp:DropDownList ID="ddl_Shift1" runat="server" AutoPostBack="true" EnableViewState="true">
            <asp:ListItem Text="d" Value="d" Selected="True"></asp:ListItem>
            <asp:ListItem Text="n" Value="n" Selected="False"></asp:ListItem>
            <asp:ListItem Text="h" Value="h" Selected="False"></asp:ListItem>
        </asp:DropDownList>
    </p>
    <p>
        <asp:RadioButtonList ID="rbl_C112" runat="server" AutoPostBack="true" EnableViewState="true">
            <asp:ListItem Text="2" Value="112" Selected="False" ></asp:ListItem>
            <asp:ListItem Text="3" Value="112" Selected="False" ></asp:ListItem>
            <asp:ListItem Text="4" Value="112" Selected="False" ></asp:ListItem>
            <asp:ListItem Text="5" Value="112" Selected="False" ></asp:ListItem>
            <asp:ListItem Text="Unassigned" Value="112" Selected="True" ></asp:ListItem>
        </asp:RadioButtonList>
    </p>    
    <p>
        <asp:Label ID="l_c112" Text="" runat="server"></asp:Label>
        <asp:Label ID="username" Text="" runat="server"></asp:Label>
    </p>
    </form>
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="ContentPlaceHolder_tutorialBar" Runat="Server">
</asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="ContentPlaceHolder_foot" Runat="Server">
</asp:Content>

VB Codebehind s_Default

Partial Class s_Default
    Inherits System.Web.UI.Page

    Sub Page_Load() Handles Me.Load
        username.Text = Session("UserRole").ToString()
    End Sub

    Protected Sub rbl_C112_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles rbl_C112.SelectedIndexChanged
        l_c112.Text = ""
        l_c112.Text = rbl_C112.SelectedItem.ToString()
    End Sub
End Class
  • 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-06-15T15:50:07+00:00Added an answer on June 15, 2026 at 3:50 pm

    It’s not the selected index which is returned after post-back, its the selected value.

    As rbl_C112 all have the same values (112), its going to select the first 1 which matches the value.

    Change the values of your DropDownList options so that they are unique and this will resolve your issue.

    <asp:RadioButtonList ID="rbl_C112" runat="server" AutoPostBack="true" EnableViewState="true">
           <asp:ListItem Text="2" Value="112" Selected="False" ></asp:ListItem>
           <asp:ListItem Text="3" Value="113" Selected="False" ></asp:ListItem>
           <asp:ListItem Text="4" Value="114" Selected="False" ></asp:ListItem>
           <asp:ListItem Text="5" Value="115" Selected="False" ></asp:ListItem>
           <asp:ListItem Text="Unassigned" Value="116" Selected="True" ></asp:ListItem>
    </asp:RadioButtonList>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there any way to change the selection bar text color in a list
I'm wondering how to change the blue highlight/selection color of a UITableViewCell , any
I am trying to make a catch-all proxy that takes any selector with any
Does any one have tried to customize default section index displayed in UITableView. I
Is there any way that I can pass arguments in selector? example: I have
Is there any way to get the text of the selector that invoked some
There are some section in the table that does not contain any data and
Are there any controls that can dynamically create a group of radio buttons from
We have a form with a radio button group, where any one of the
I have a ListBox that is styled to use RadioButtons , and changing the

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.