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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T14:27:18+00:00 2026-05-27T14:27:18+00:00

I inserted an ASP.NET check box list control inside an AJAX tab container. Now

  • 0

I inserted an ASP.NET check box list control inside an AJAX tab container. Now I need to create an object of that control to access the check box list in my C# code behind file.

Here is my HTML where I created my check box list:

<ajaxToolkit:TabContainer ID="tcPrescription" runat="server" Height="444px">
    <ajaxToolkit:TabPanel runat="server" ID="indoor" Height="430px">
        <HeaderTemplate>
          Indoor Prescription
        </HeaderTemplate>
        <ContentTemplate>
            <div id="bottomcontainer" style="height:420px;">
                <div id="bottomleft" style="float:left;height:420px;width:400px;text-align:center;">
                    <asp:Panel ID="pnlMedicines" runat="server" HorizontalAlign="Center" 
                        ScrollBars="Vertical" Height="375px" Width="389px">
                    <center>
                        <asp:CheckBoxList ID="cblMedicines" runat="server" BackColor="White" 
                            BorderColor="#669900" BorderStyle="Solid" BorderWidth="1px" 
                            Height="350px" Font-Bold="False" ForeColor="Black" Width="316px"
                            DataSourceID="dsMedicines" DataTextField="MedicineName"
                            DataValueField="MedicineName" >
                        </asp:CheckBoxList>
            ...
        </ContentTemplate>
    </ajaxToolkit:TabPanel>
</ajaxToolkit:TabContainer>

And here is my code in the code behind file:

CheckBoxList cblMedicines = (CheckBoxList)tcPrescription.FindControl("cblMedicines");

It returns a null object for cblMedicines. So how can I access a check box list control inside an AJAX tab container?

Please help me with this.

  • 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-27T14:27:19+00:00Added an answer on May 27, 2026 at 2:27 pm

    You can try using

    CheckBoxList cblMedicines = (CheckBoxList)pnlMedicines.FindControl("cblMedicines");
    

    instead.

    cblMedicines resides in the pnlMedicines control; looking for it under the latters children is more common.

    good luck!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am doing a really simple query in ASP.NET, but after I inserted the
I've got problems with special characters being inserted and displayed properly. It's an ASP.NET
I'm working on a ASP.NET site with C# code. Now the trouble starts when
in asp.net mvc, if u create a simple site, some security code will be
For an asp.Net MVC project, I will need to handle large files( mostly 200-300Mo,
I'm using the FormView control in ASP.NET for a simple form to insert into
I have an Ajax.Net enabled ASP.Net 2.0 web site. Hosting for both the site
We have an ASP.NET web application which uses ASP.NET Ajax. We open it from
I have an ASP.NET page with a Wizard control containing several pages of form
I am working on an asp.net application. I need help designing the database related

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.