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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T00:15:20+00:00 2026-06-15T00:15:20+00:00

I have 10 asp:Panel ‘s that include a fieldset with asp:labels and asp:textboxes in

  • 0

I have 10 asp:Panel‘s that include a fieldset with asp:labels and asp:textboxes in order to retrieve the data of contact details for a company. I would like to add and delete panels(contact details fieldset) and I have followed the following approach to solve my problem.

At the beginning I have these 10 panels, and only 1 panel is Visible, the remaining 9 are InVisible. When the user desires to add a new contact the following panel changes to Visible = true. Same approach is followed for the deletion of this particular panel(contact details fieldset), I put the particular panel.Visible = false and all its fields clear.

Since the company is able to retrieve for maximum 10 contacts (their details – translate to 10 panels), my problem arises when the user desires after a while to add a new panel after deletion.

For example, the user adds Panel 1 – Panel 2 – Panel 3 for three contacts. Then he deletes Panel 1 and thereafter he desires to add another Panel. Then my program finds how many panels are available yet (visible= false) in order to create the next Panel ( since max Panels = 10), however based on the above scenario my program creates Panel 1 again at the same position like the page load ( to wit above Panel 2), but if Panel 4 is the following available will create it down of Panel 3 and this causes confusion to the user. The new Panel is created above or down of the last Panel depending on the rest of available panels (if the number of following panel is smaller or bigger of the last).

How can I fix my problem or am I following a completely wrong approach? I tried to use JavaScript to add new controls but I found many difficulties to recognize the IDs of each controller in order to store the data to my Database.

  • 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-15T00:15:22+00:00Added an answer on June 15, 2026 at 12:15 am

    Instead of creating panel in the ASPX page you may create your panels and other controls in the code behind and then you can add them on the page from code. (This way you may add more than 10 panels if required)

    In Code behind.

    Panel panel1 = new Panel();
    panel1.Controls.Add(yourLabel); // add your dynamically created controls
    this.Page.Controls.Add(panel1); // add the panel to your page
    

    Or you can create a user control with panel and other controls, load the control from the code and add them on the page. For user control you may look at the following resources.

    ASP.NET User Controls – MSDN
    User controls in ASP .NET – CodeProject

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

Sidebar

Related Questions

I have an asp.net 3.5 update panel and I have a few textboxes that
I have an Asp.Net 4.0 website/control interface that uses an update panel and some
I have an asp.net panel that contains a checkboxlist. I'd like to resize it
I have an ASP.NET Panel that has a gridview inside of it. Below is
I have a modal popup extender tied to a asp:panel control that I want
I have a asp Panel that opens as a Modal Popup window using ajax.
I have an ASP panel with a modalpopupextender attached to it that is shown
I have an ASP.Net Update Panel which contains controls that I am trying to
I'm using asp.net(C#) under visual studio 2010 I have a panel that is by
I have an AJAX Modal Popup panel that contains a RadioButtonList, 2 labels and

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.