473,320 Members | 1,846 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Updating TabPanel contents asynchronously

Hi folks,

I've been trying to work out how to asynchronously update the contents
of a TabPanel using an UpdatePanel and I can't for the life of me get
it to work. I've seen a couple of examples online that declare an
UpdatePanel inside a TabPanel, but I get an error when I try and do
something like the following:

<ajax:TabContainer runat="server" ID="TabList" ActiveTabIndex="0">
<ajax:TabPanel ID="ContentTab1" HeaderText="Tab 1">
<ContentTemplate>
<asp:UpdatePanel runat="server" ID="AsyncContent1"
UpdateMode="Conditional">
<ContentTemplate>
<!-- Some content here -->
<asp:Button runat="server" ID="UpdateButton"
OnClick="UpdateButton_Click" Text="Update" />
</ContentTemplate>
</asp:UpdatePanel>
</ContentTemplate>
</ajax:TabPanel>
</ajax:TabContainer>

The error I get is, "TabContainer cannot have children of type
'System.Web.UI.UpdatePanel'.". Looking at the code for the
TabContainer class, I can see that the AddParsedSubObject method
throws an HttpException if the control being parsed is not a TabPanel
or a LiteralControl. Am I missing something crucial here, or is it
simply not possible to asynchronously update the contents of a
TabPanel and the examples I have seen are in fact completely wrong?

Thanks in advance for any help that you can give me!
Jun 27 '08 #1
1 2440
Hmmm. I've just noticed that it was because I forgot to put
runat="server" in my TabPanel. Oops!

On May 1, 11:37*am, Wazzamatazz <grahamcharleswa...@googlemail.com>
wrote:
Hi folks,

I've been trying to work out how to asynchronously update the contents
of a TabPanel using an UpdatePanel and I can't for the life of me get
it to work. *I've seen a couple of examples online that declare an
UpdatePanel inside a TabPanel, but I get an error when I try and do
something like the following:

<ajax:TabContainer runat="server" ID="TabList" ActiveTabIndex="0">
* * <ajax:TabPanel ID="ContentTab1" HeaderText="Tab 1">
* * * * <ContentTemplate>
* * * * * * <asp:UpdatePanel runat="server" ID="AsyncContent1"
UpdateMode="Conditional">
* * * * * * * * <ContentTemplate>
* * * * * * * * * * <!-- Some content here -->
* * * * * * * * * * <asp:Button runat="server" ID="UpdateButton"
OnClick="UpdateButton_Click" Text="Update" />
* * * * * * * * </ContentTemplate>
* * * * * * </asp:UpdatePanel>
* * * * </ContentTemplate>
* * </ajax:TabPanel>
</ajax:TabContainer>

The error I get is, "TabContainer cannot have children of type
'System.Web.UI.UpdatePanel'.". *Looking at the code for the
TabContainer class, I can see that the AddParsedSubObject method
throws an HttpException if the control being parsed is not a TabPanel
or a LiteralControl. *Am I missing something crucial here, or is it
simply not possible to asynchronously update the contents of a
TabPanel and the examples I have seen are in fact completely wrong?

Thanks in advance for any help that you can give me!
Jun 27 '08 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: smnbss | last post by:
Hi to all I've a repeater into a TabContainer->TabPanel->ContentTemplate but nothing is showed.. anyone know why? tks in advance simone
2
by: quelle | last post by:
I have a TabContainer with three TabPanels. What I'd like to do is call a javascript function (with some custom parameters) every time a tab is clicked. Here is a simplified example: ...
0
by: axxon | last post by:
hi, I am having a huge problem here! the scenario is i am trying to create dynamic accordion Panes to a accordion control inside a tab panel in a content page. It works just fine in a regular...
0
by: vincent.defarge | last post by:
hi, I have a page that contains a tabpanel and a button which allow to change the mode of my tabpanel. my tabpanel has 2 modes : -"all elements disabled" -"all elements enabled" The tabpanel...
0
by: fran_j_diaz | last post by:
Hi, I've got some web pages whiches are too heavy. My pages have TabPanels and I saw that it was possible to load a tabPanel when we click in instead of the page loading. I went to ...
3
by: GunnarJ | last post by:
I have an Ajax TabContainer. I also have a simple javascript function that normally can update a textbox using 'document.getElementById' This works as expected when the textbox is outside the...
2
by: =?Utf-8?B?TWlrZQ==?= | last post by:
Hi. I'm trying to add a System.Web.UI.UserControl (Not a System.Web.UI.WebControl) to an asp.net ajax tabpanel. Unfortunately it doesn't appear that this is possible. This question could get...
1
by: ysudhakarrao | last post by:
Hi i am having two pages main.aspx and popupwindow.aspx .In main.aspx i am having tabpanel and button.popupwindow.aspx iam having listbox ie collection of webusercontrols.after click of that...
1
by: tutus | last post by:
Hi, I have a tabcontainer with 3 TabPanels. Hers is my reel purpose: I need to put a label on the right side of the last TabPanel' s header. This last TabPanel is the 3rd TabPanel in my...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.