Showing posts with label toolkit. Show all posts
Showing posts with label toolkit. Show all posts

Wednesday, March 28, 2012

Tab container - Progressive enhancement

I am new to AJAX and the control toolkit.

I read about "Graceful degradation/Progressive enhancement" on another site and I am wondering how I can code for it when I use a tab container. I was testing with the AJAX tab container/tab panel but when I disable javascript in the browser, the page with the tab is blank. On some sites using tabs, the result of turning javascript off is different. The page shows atleast the first tab's information but nothing happens when the second tab is selected.

I realize I can add a message - "this site needs javascript to be turned on" or redirect the user to another page if javascript is disabled. I am wondering if there is anything else I can do so the page does not show up blank.

Thanks!

Hi,

May be you can try this.

Add a pure text-based header, set its visibility to hidden via javascript on load.

So that it will be visible if the javascript is disabled.

Hope this helps.


The Toolkit is not supported to work if javascript is turned off. The behavior may not be tuned to gracefully degrade and it is not a scenario we plan to solve since the Toolkit controls all operate in client side ASP.NET AJAX behaviors which need javascript to be turned on and it may be hard to do the same. If you are using the Toolkit on sites which may be expected to work when javascript is turned off then it may need to be taken care of in your code.

TAB CONTAINER AJAX TOOLKIT

Good Day!!!I'm trying to used Tab Container (Ajax Toolkit) but i need more than 20 tab panels in 1 tab container. The problem is the tab panels I added in the tab container is not fixed to the tab container. Can you help me to fix my problem thank you...marc

Hi

The problem is the tab panels I added in the tab container is not fixed to the tab container?What do you mean?

Please refer to http://ajax.asp.net/ajaxtoolkit/Tabs/Tabs.aspx for help.

Tabs Description

TabContainer is an ASP.NET AJAX Control which creates a set of Tabs that can be used to organize page content. A TabContainer is a host for a number of TabPanel controls.

Each TabPanel defines its HeaderText or HeaderTemplate as well as a ContentTemplate that defines its content. The most recent tab should remain selected after a postback, and the Enabled state of tabs should remain after a postback as well.

Thanks


hi Good Day! I have a tab container with 16 tab panels, and I set the width style of the tab container (770px) , the problem is the other tab panelsis not fixed to the 770px(width of the tab container) and continuesly going to the right. Hope you can help me to my problem thank you.

Tab Control

Does anyone know how to make the tabs on a TabControl that comes with the Ajax control toolkit to display its tabs on multiple rows and not just on one long row?

Thanks in advance

your're not the only one... vote here!

http://www.codeplex.com/AtlasControlToolkit/WorkItem/View.aspx?WorkItemId=8843

Big Smile

Cheers!


Thanks. Hope we get the feature Soon!

Tab Control - Enable/Disable Tab on Client

I'm using the AJAX Toolkit TabContainer control and would like to enable/disable tabs on the clientside. I have tried document.getElementById('MyTabContainer').get_tabs()[1].set_enabled(true), but I get the error "Object does not support this property or method." Just to try to capture the appropriate object, I added the OnClientActiveTabChanged="switchTab" attribute to my TabContainer. Then, in JavaScript I wrote a switchTab function: function switchTab(sender, e){ ... } Thesender passed into the switchTab function is the actual TabContainer object I need, and from that I can enable/disable tabs. My problem is I can't figure out how to retrieve the TabContainer object other than capturing the object when sent into the switchTab routine. Any ideas?

Finally solved my own problem, and it was right there in the sample Tab application in the Control Toolkit: http://ajax.asp.net/ajaxtoolkit/Tabs/Tabs.aspx. I was able to find the object I needed in JavaScript using the $find method, as similarly done in the demo with the following snippet:

function ToggleHidden(value) {
$find('ctl00_SampleContent_Tabs').get_tabs()[2].set_enabled(value);
}

Monday, March 26, 2012

Tab Control (Doubts)

Hi Everybody...

I have a two questions:

1 - How do it does a Tab Control of the a Tab Container (Ajax Control Toolkit) to load the content, when it will only called (clicked) ? Because i have some data-sources in my page, and this leaves the slow page! (Sample: The tab Related or Preview, this forum!)

2 - How do I do a window pop-up (with drag and drop), equal the window of Contact (Send Email) this forum ??? to do the window not to leave the area of the navigator outside.

Thank all!

Felipe Oriani:

up


If you look at the thread titled "TabContainer and ActiveTabChanged" it'll tell you how to go about this

Tab Control Documenation

I'm new to AJAX and I'm trying to find documenation on the Tab control in the AJAX ToolKit. Untimately, I need to progammatically control each tab (HeaderText, content in each tab, etc.). I'm not having much luck so far finding documentation that describes all the properties and methods and how to use them programmatically. Any suggestions?

Thanks!

I have resolved the problem of prgrammatically setting the HeaderText and tab contents by creating User Controls and using the LoadControl method during the Page_Load event.

Chris

tab control not visible

Hi,

I have a project in to which i added the ajax control toolkit.Then i added the tab container to a page.

The are no errors while compiling ,But the tab control is not visible in the page after running.The code is as follows

<table width="100%" cellSpacing="1" cellPadding="0" align="left">

<tr>
<td style="width: 100%">
<ajaxToolkit:TabContainer runat="server" ID ="tabs" OnClientActiveTabChanged="ActiveTabChanged" ActiveTabIndex="0">
<ajaxToolkit:TabPanel ID ="panel1" runat="server" HeaderText=" Personal ">
<ContentTemplate>
<table width="100%" cellSpacing="1" cellPadding="0" >
<tr>
<td style="width: 110%">
<table width="100%" cellSpacing="1" cellPadding="0" align="left">
<tr>
<td class="itemcolor" >

Employee Id:</td>
<td class="itemcolor"><asp:TextBox ID="txtEmpCode" runat="server" width="198px"></asp:TextBox>
</td>
<td class="itemcolor" width="50"></td>
<td class="itemcolor">
Access Rights:</td>
<td class="itemcolor"><asp:DropDownList ID="ddlAcessRights" runat="server" Width="198px"></asp:DropDownList></td>
</tr>
<tr>
<td class="itemcolor" width="198"></td>
<td class="itemcolor" width="198"></td>
<td class="itemcolor" ></td>
<td class="itemcolor" width="198"></td>
<td class="itemcolor" width="198"></td>
</tr>
</table>
</td>
</tr>
</table>
</ContentTemplate>
</ajaxToolkit:TabPanel>
<ajaxToolkit:TabPanel ID ="panel2" runat="server" HeaderText=" Official ">
<ContentTemplate>
<table>
<tr>
<td>
<asp:TextBox runat="server" ID="test"></asp:TextBox>
</td>
</tr>
</table>
</ContentTemplate>
</ajaxToolkit:TabPanel>
</ajaxToolkit:TabContainer>

</td>
</tr>
</table>

Please help me

Thanks and regards

Prathibha

Hi,

I made a new page and copied your tabContainer-code into it and it displays just fine!

Do you get any errors?

Does other Ajax functionality work?

Do other ajaxControlToolkit-controls work?

Can you post the code of the whole page?

Please answer my questions!

Kind regards,
Wim


Couldn't see an error, so it must come from something else on the page.. Wild guess: rounded corners extender?

Edit:

- I copy pasted this exact code in a test.aspx..

- added the scriptmanager.

- got a javascript error saying: "ActiveTabChanged is undefined".Which is correct.. (And nothing showing.)

--> So I removedOnClientActiveTabChanged="ActiveTabChanged"

And then the page displayed correctly..


hi,Thanks to all.I got it correct.But i am not able to access the controls placed in the content template using javascript.

I have a textbox "txtEmpCode" placed in the content template of tab control.then i tried to access it as follows

document.getElementById("txtEmpCode")

But im getting null value

please help..

thanks n regards

prathibha


Hi Prathibh,

To access the control , please do it like this. $get("<%=txtEmpCode.ClientID%>"). $get equals to document.getElementById.

Best regards,

Jonathan


You needs to change your web config file for ajax supporting...for these you take File->New website->Ajax enabled website...and copy the special tags for ajax into your webconfig....

Tab custom style lost on postback

I just downloaded the new Ajax toolkit Release 10920 and found that my custom style for the Tab control is lost on postback. When the page is first loaded, my tabs look correct, but after postback my tab css style is not fully rendered. It seemed to revert back to the default style. This has been working with all previous toolkit releases.

Below is my custom style which I've copied to my own custom .css file and made a few minor changes :

/*Tab Style*/
/* default layout */
.ajax__tab_default .ajax__tab_header {white-space:nowrap;text-align:left;padding-left:20px;padding-top:10px;}
.ajax__tab_default .ajax__tab_outer {display:-moz-inline-box;display:inline-block}
.ajax__tab_default .ajax__tab_inner {display:-moz-inline-box;display:inline-block}
.ajax__tab_default .ajax__tab_tab {margin-right:4px;overflow:hidden;text-align:center;cursor:pointer;display:-moz-inline-box;display:inline-block}

/* xp theme */
.ajax__tab_xp .ajax__tab_header {font-family:verdana,tahoma,helvetica;font-size:11px;background:url(../images/tab-line.gif) repeat-x bottom;}
.ajax__tab_xp .ajax__tab_outer {padding-right:4px;background:url(../images/tab-right.gif) no-repeat right;height:21px;}
.ajax__tab_xp .ajax__tab_inner {padding-left:3px;background:url(../images/tab-left.gif) no-repeat;}
.ajax__tab_xp .ajax__tab_tab {height:13px;padding:0px;padding-top:4px;padding-bottom:4px;margin:0;background:url(../images/tab-little.gif) repeat-x;}
.ajax__tab_xp .ajax__tab_hover .ajax__tab_outer {background:url(../images/tab-hover-right.gif) no-repeat right;}
.ajax__tab_xp .ajax__tab_hover .ajax__tab_inner {background:url(../images/tab-hover-left.gif) no-repeat;}
.ajax__tab_xp .ajax__tab_hover .ajax__tab_tab {background:url(../images/tab-hover.gif) repeat-x;}
.ajax__tab_xp .ajax__tab_active .ajax__tab_outer {background:url(../images/tab-active-right.gif) no-repeat right;}
.ajax__tab_xp .ajax__tab_active .ajax__tab_inner {background:url(../images/tab-active-left.gif) no-repeat;}
.ajax__tab_xp .ajax__tab_active .ajax__tab_tab {background:url(../images/tab-active.gif) repeat-x;}
.ajax__tab_xp .ajax__tab_body {font-family:verdana,tahoma,helvetica;font-size:10pt;border:0;padding:0px;background-color:#ffffff;}

Has anyone encountered this problem with the new release?

Thanks,
Jensayato

Hi,

Can you ellabrote more..

So it will be more helpful to solve your problem.

Tab Panel

Hello Everyone,

I've been working with the tab panel example in the AJAX Control Toolkit and I have a problem I just cannot seem to solve. How would I cause a click on a specific tab to call a specific function on the C# code behind page? Is this something I can do on the C# side? If not, you might have to give some example code as I'm a newbie at ASP.NET and Javascript. Thanks in advance.

Robert

hi Robert,

The tab Panel/container does not have an autopost back mechanism. So you must do it your self by adding;

"text/javascript"> function ActiveTabChanged(sender, e) { __doPostBack('<%= tc1.ClientID %>', sender.get_activeTab().get_headerText()); }

<scripttype="text/javascript">

function ActiveTabChanged(sender, e)

{

__doPostBack('<%= tc1.ClientID %>', sender.get_activeTab().get_headerText());

}

</script>

andset the OnClientActiveTabChanged="ActiveTabChanged"


The previous answer didn't quite do everything required for you.

Add the following script to your page:

<script type="text/javascript" language="javascript">
function ActiveTabChanged(sender, e)
{
__doPostBack('<%= idofmytabcontainer.ClientID %>', sender.get_activeTab().get_headerText());
}
</script>


Then ensure your markup for the tab container has the following entries:

OnClientActiveTabChanged="ActiveTabChanged" OnActiveTabChanged="ActiveTabChangedServer"

In the page load event of your code behind file add:

ScriptManager1.RegisterAsyncPostBackControl(idofmytabcontainer);


Finally add the ActiveTabChangedServer method to the code behind file:

protected void ActiveTabChangedServer(object sender, EventArgs e)
{
if (idofmytabcontainer.ActiveTab == idoftabpanel1)
{
//Do something in code
}

if (idofmytabcontainer.ActiveTab == idoftabpanel2)
{
//Do something in code
}
}

I hope that helps


Does anyone have a sample tab panel that is working that they can paste below (or e-mail to me)? I'm making a mistake somewhere and cannot figure out where. If I had a sample tab panel that is already working correctly I can work from there. Thanks in advance.

Robert


Robert, the above code worked for me (when I checked it with a break point in Visual Studio), but the msgs I wanted to display didn't display. Then I put in an UpdatePanel around the labels and added a trigger and the messages showed. Here is what I added on the panel that was clicked:

<asp:UpdatePanelID="UpdatePanel7"runat="server">

<ContentTemplate>

<asp:LabelID="lblEmailMsg"runat="server"ForeColor="red"Font-Bold="true"/>

<asp:LinkButtonrunat="server"ID="lbtnAssignEmail"Visible="true"Text="Click here to fix this."/>

</ContentTemplate>

<Triggers>

<asp:AsyncPostBackTriggerControlID="Tabs"EventName="ActiveTabChanged"/>

</Triggers>

</asp:UpdatePanel>


Actually, here is the correct linkbutton control, but it is not really part of the solution. I just was not ready to test the link button yet so I left out the OnClick.

<asp:LinkButtonrunat="server"ID="lbtnAssignEmail"Visible="true"OnClick="OnClickPanel1"Text="Click here to fix this."/>


zoetosis,

I am using masterpages and my script manager is in the masterpage, how do I add the RegisterAsyncPostBackControl in page_load when I am using master pages.

Thanks


In VB:

ScriptManager.GetCurrent(Me.Page).RegisterAsyncPostBackControl([nameoftabcontainer])

Saturday, March 24, 2012

Tab Panel using ContentPlaceHolder not working inside Master Page.

I just downloaded the latest version of the AJAX toolkit and have noticed that with the new version my master pages now have new errors. It seems that the tab panels cant be used in master page and using contentplaceholders. Anyone have any fixes or solutions for this. The error I get is

Error 1 'AjaxControlToolkit.TabPanel.TabPanelContainer' is inaccessible due to its protection level c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\pubsubgui\6a434f43\4362c5b0\App_Web_dl4gjyhw.0.cs 185

Hi,

You can modify the access identifier of TabPanelContainer from internal to public in the source of the AjaxControlToolKit to solve it.


This should be fixed in the next release of the Toolkit due soon. Thanks!


Has this been resolved? I downloaded the Jun 18 release but I still seem to be having this issue (first time Ive used the control toolkit, so I cant tell you if it existed for me previously).

I have a content place holder in my Master page, and Im using the Tab Container/Panel control in my content page. The content pane renders blank. If I view source on the page the style for the tab container/panel is set to visibility:hidden;display:none; I have no idea why that happens but that might be part of the issue (Ive set the Style manually in the page_load but it doesnt act like a tab control, rather i just see the tab panel header text).

-Chris


Please send along a simple, self-contained demonstration of the problem for folks to have a look at. Maybe have a peek at the Tabs sample page which also uses MasterPage/ContentPage and seems to work okay.


OK, so this is my first time using AJAX, and the first control im using, and im already getting a fatal error like this?? Am I going to have problems like this with other controls? Should i wait on using AJAX?? It doesnt seem like its quite ready to use in a professional setting, with deadlines. Thanks


Hey... In general the AJAX toolkit is great and really fleshes out more for your web page. If you go and get the latest change source... this has been fixed. Go here and download and build the latest version of the code.http://www.codeplex.com/AtlasControlToolkit/SourceControl/ListDownloadableCommits.aspx


OK, isnt there a way to just download all of the fixes? I dont know what I am looking for in that link. Maybe the June 18th entry at 1:06 by davidans "take care of code analysis issue in tabpaneldesigner" ?? Sounds like person above downloaded that with now help. And how do I know where to add this souce code?? I build it into that sample project that comes with the toolkit?? And use the DLL it creates??

Tab Panel Problems

Hello Everyone,

I am using the tab panel that came with the AJAX Toolkit basically the same as the sample Tab Panel. I'm using OnPrerender to show dynamic content on the tab panels (based on what the user enters on the first panel). My problem is that all the panels are being filled even though they are not currently active and may never be selected by the user. Onprerender calls a C# function which determines content for each individual panel. There is a separate function for each separate panel (in C#). What code can I add so I can prevent the C# function from being called until they actually click on that particular Tab? If you need to see the site to understand the problem better you can go towww.visual-search.net and try a sample search. The problem will be obvious I think. Thank you in advance.

Robert

Hi Robert,

To load data for only the currently Visible Tab , you can subscribe to the "ActiveTabChanged" Event on the Server-Side and depending on the

Current ActiveTabIndex , you can

Unfortunately, there are some issues with this property .

There is a work-Item opened to track this

http://www.codeplex.com/AtlasControlToolkit/WorkItem/View.aspx?WorkItemId=7739

Jason Hill has a work-around for this Property which is also mentioned in the WorkItem .

For clarity , I will repeat it here.

<blurb>

JasonHill wroteMar 15 at 11:23 PM

You can workaround this by creating a JS function:

function ActiveTabChanged(sender, e)
{
__doPostBack('<%= TabContainer.ClientID %>', sender.get_activeTab().get_headerText());
}

and then assigning this as the event handler for a client tab change in the tab container:

OnClientActiveTabChanged="ActiveTabChanged"

Looking forward to the autopostback property though!

</blurb>

Hope this helps

TabContainer - Two Components with the same id error

Hi. I've loaded the most recent AJAX Controls Toolkit and am using a TabContainer and TabPanels. I try to run a report from Oracle by clicking on an image button elsewhere on the screen, which should (and does) cause the report to be generated. It then is to switch TabPanels and show the report. At that point, I get:

Microsoft JScript runtime error: Sys.InvalidOperationException: Two components with the same id 'TabContainer1_TabPanel1' can't be added to the application.

I've researched on the forums and found a few proposed fixes to this issue. Unfortunately, none of them seem to work. Has anyone seen this with the TabContainer, and is there a fix? If I set debug=false in the web.config it goes away, but I realize that isn't truly a solution.

Regards,

Mark

Hi Mark,

I am having similar problem. My case was, I have a user control that contains MultipleSelectorExtender from ajax control toolkit. On my page, I need to hide and show this user control on a specific event. The first time I set the Visible property of this user control that contains the MultipleSelectorExtender, I am not getting any error. The next time that I attempted to set the visible property of the usercontrol to true, I got the error message "Sys.InvalidOperationException: Two componnents with same id '<multipleselectorextender's Id>' can't be added to the application."

It seems that the component was recreated again when the container wast set to visible.

Have you found solution to your problem? If so, kindly post it here.

tia,

/randz

TabContainer and FormView

Hello,

I would like to replace our current tab solution with the tab controls found in the ajax control toolkit. I've spent a few days trying to get the tabs to operate in the manner I would like and was wondering if anyone could explain the best way to use TabContainer and FormView controls together.

Basically, I would like to do the following:
<asp:SqlDataSource ... /><asp:FormView ...><EditItemTemplate><ajaxToolkit:TabContainer ...><ajaxToolkit:TabPanel ID="Panel1" ...>...</ajaxToolkit:TabPanel><ajaxToolkit:TabPanel ID="Panel2" ...>...</ajaxToolkit:TabPanel></ajaxToolkit:TabContainer></EditItemTemplate></asp:FormView>

When I build pages based on this - Update and Insert commands fail with "You must declare the scalar variable XXX" errors as the formview cannot find the editing controls inside the TabContainer because it is an INamingContainer. I have tried using multiple FormView controls (one for each tab panel) in concert to update & insert records - however the amount of custom code required is unacceptable.

The solution I choose has to be very reusable as we have hundreds of different pages (like this) in production. At this point I am considering writing my own client side tab control as I would like to come up with a solution as quickly as possible and I've hit a number of dead ends.

Does the ajax control toolkit support using a FormView that contains a TabContainer (am I just missing something)? Are there any good workarounds? Are there plans to add this kind of support in the future?

Any answers or information will greatly help me make my decisions. Thanks in advance,
J. Shane Kunkle

jkunkle@dotnet.itags.org.vt.edu

Any input or advice is appreciated...

Hi Shane,

I think it's not that easy to make works perfectly in your situation now.

Can you try to add a public property on the TabContainer, and take it as a parameter?


I'm sorry - i'm not sure i understand your advice. Are you advising that I should create a class that inherits from TabContainer - what would the new property do?

Thanks again for the assistance,

Shane


Yes, or you can change the its original code since it's provided.

Wednesday, March 21, 2012

TabContainer Causes An Error When Rendering

I have been using theTabContainer for the past several months and like the way it works. After upgrading to the most recent version of the toolkit I now get an error when rendering any page that has a TabContainer. I updated the DLL's in my bin folder. The toolkit sample website works ok.

I tested with a page that has no other TabContainers, just the segment shown below and continue to get the error.

<ajaxToolkit:TabContainerID="TabContainer1"runat="server">

<ajaxToolkit:TabPanelID="TabPanel1"runat="server">

<ContentTemplate>

</ContentTemplate>

</ajaxToolkit:TabPanel>

</ajaxToolkit:TabContainer>

Is ther something I need to do to the web.config file 0r is there some other issue?

Error...

{"The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>)."}

The error occures in ScriptObjectBuilder at the hightlighted line shown below...

public

staticvoid RegisterCssReferences(Control control)
{
foreach (string styleSheetin ScriptObjectBuilder.GetCssReferences(control))
{
// Add the link to the page header instead of inside the body which is not xhtml compliant
HtmlLink link =new HtmlLink();
link.Href = styleSheet;
link.Attributes.Add("type","text/css");
link.Attributes.Add("rel","stylesheet");
control.Page.Header.Controls.Add(link);
}
}

This has been resolved... please follow this link for the answer...

http://forums.asp.net/thread/1617139.aspx


I have a Web Application where I want to use a TabContainer but when I load page it the control it is not loaded.
I should carry out a postbak in it page it and it is loaded somebody knows like I can solve it.

TabContainer and Validator

I'm new to the toolkit... Can you use RequiredFieldValidator to validate a textbox when the user clicks on a different TabPanel in the TabContainer? I imagine that you can write your own JS. Thoughts?

Thanks!!!

Hi,

According to my understanding to your question, you are trying to prevent the other TabPanel from being actived if current TabPanel has validators that fail to validate. Isn't it?

As far as I know, the TabContainer doesn't expose an event that fires before the active panel is changed. So, you may try an alternative method. The basic idea is as follows:

1. Add an activeTabChanged event handler to the TabContainer
2. When a tabPanel is actived, save its index in a global variable
3. In the activeTabChanged handler, check if all Validators in previous tabPanel are valid. If not, set current active index to the index stored in global variable.

You may have the following code:

function pageLoad() {
tc = $find("TabContainer1");
tc.add_activeTabChanged(onChanged);
}

var index = 0;

function onChanged(sender, e) {
tc = $find("TabContainer1");
if( !Page_Validators[0].isvalid ){ // I assume validators[0] is in previous panel here. For practical usage, you may have to implement a strategy to organize validators in different panels
tc.set_activeTabIndex(index);
}
else{
index = tc.get_activeTabIndex(index);
}
}

Though this approach is not that straight, still hope this can helps.

TabContainer flicker on tab mouse over

Hi,

I am using the AJAX Control Toolkit and have a TabContainer with two TabPanels on an aspx/VB page.

My problem is when I mouse over the tabs the page flickers.

Putting the TabContainer in an UpdatePanel makes no difference.

From what I have gathered this is due to the reloading of the tab images used by the 'ajax__tab_xp' CSS that is applied by default to the TabContainer.

Can anyone suggest a way to prevent the flicker (other than changing the cache settings in IIS)?

Apologies if this is a double up post (I looked and couldn't find any that answered the problem).

Thanks in advance,
David

I have this problem too! I noticed, however, that the 'demo' Ajax Toolkit site doesn't have this problem. there must be a way to prevent this, looks terrible.


Hi abgibbs,

I have not found a proper fix to this problem but this post http://forums.asp.net/t/1115791.aspx helped me to bang together a temporary hack fix.

I basically rewrote the entire Tabs CSS file so that it was no longer using background:url(<%=WebResource("AjaxControlToolkit.Tabs.tab-hover-left.gif")%>)to populate the background images of each TabPanel.

I made my own background images and imported them into my projects Images folder and now havebackground:url("./Images/TabIcon.gif")repeat-x ; in my StyleSheet.

It doesn't look nearly as good as the real deal but at least it no longer has that horrific flicker.

Hope this helps,
David


I don't see any problem on my tabpanels when hovering over the tabs ...


I've been using the tabcontainer a lot...

And there's obviously something weird about it: if you move your mouse over the headers, very often the content of the active tabpanel will "jump". If you have some text inside you will see it suddenly wrap differently for a second, for example.

I haven't found a way around it, but haven't really tried until now...

But moving your mouse over the headers has an effect on the size of the active TabPanel.

TabContainer in an UpdatePanel (.NET 3.5)

I have recently upgraded a website from ASP.NET 2.0 and the appropriate AJAX Control Toolkit to use .NET 3.5 (with Visual Studio 2008 Beta 2) and the AJAX Control Toolkit that is available for the version. My website has several pages with a TabContainer inside an UpdatePanel. However now when an asynchronous postback occurs from buttons either inside the TabContainer or outside the TabContainer, the entire TabContainer seems to flicker. Note that only the TabContainer and it's contents seem to flicker and not the other contents outside of the TabContainer. Is anyone else experiencing results like this?

Thanks,

Kyle

I am experiencing the exact same problem. I have a tab container inside one update panel. I had no problems doing this on 2.0. I upgraded to 3.5 and on my new project my entire tab container is redrawn on every post back. When I click on a new tab, the content appears instantly, then it quickly redraws. Not sure if this is a bug, but cannot find any answers. Thanks for any help.

Wayne

TabContainer is just invisible

Hi,

this is the first time I work with the Ajax toolkit.


I want to put a TabContainer on my Usercontrol, with three tabs.

It works, it is rendered but it just doesn't show.

It keeps having the inline style definition 'visibility:hidden'.

Does anyone know how to remove this?

Thx

This happened to me awhile ago and I hated it! In IE6/7 the tab renders fine but in FF it is hidden.

I managed to find the culprit for my situation, not sure will it help you.

Basically my tab container had 3 panels, in each tab panel I added a user control. My problem was one of the user controls have a calendar extender toolkit control that had a ondateselection client side event added. Once i removed that event it worked.


I don't think the tabcontainer is to blame... Tested, used with firefox here..

But, I have seen stuff disapeering when using rounded corners extender sometimes. Maybe you have that or something else wrapped around your tabcontainer?


I'm also having this problem. If anyone has the solution it would be greatly appreciated.

<div id="ctl02" class="ajax__tab_xp" style="visibility:hidden;"><div id="ctl02_header"><span id="__tab_ctl02_ctl00">Test Header</span></div><div id="ctl02_body" style="height:150px;"><div id="ctl02_ctl00"> Test Content </div></div></div>

Ive just solved this problem. I simply removed 'OnClientActiveTabChanged="ClientFunction" ' which was still in there from when I took the code from the Sample Website. boonaap, I hope this solves your problem too. It sounds like it might since youre having an identical problem.


well eh it didn't,Confusedit was even a bit more eh stupid

Forgot to add all the info in the web.config...

Yes Iknow :)=)

don't ask

TabContainer or TabPanel break focus

Hi,

this is probably a simple problem, but I can't find a solution in this forum. I'm getting started with the AJAX Control Toolkit and set up a quite simple testpage:

There is a table, in one cell there is an update panel with some textboxes. I can place focus on one of these boxes regularily using eg "this.TextBox2.Focus();" in Page.Load.

As soon as I put a TabContainer and a TabPanel around the update Panel, the focus doesn't work anymore. I tried several methods of setting focus described in this forum, it simply doesn't work.

Any hint would be greatly appreciated!

Kind regards,

Sven

Might be related to this post, but I wan't able to make any use of it:

http://forums.asp.net/thread/1485462.aspx


Sorry, I intended to point to this post as a related issue, but the other one might have the same problem with the accordion:

http://forums.asp.net/thread/1675357.aspx


I know how you feel. I looked for HOURS about how to do this. I finally found this somehow. Make sure you place this code at the BOTTOM of your ASP.Net page. It has to be at the bottom because the Sys has to come after the script manager. (or at least that is what it seems. It will give errors at the top.) Just replace txtPartNo with your control name.

<script language="javascript" type="text/javascript">
Sys.Application.add_load
(
function()
{
window.setTimeout(focus, 1);
}
)
function focus()
{
try
{
document.getElementById('<%=txtPartNo.ClientID %>').focus();
}
catch(err)
{
//do nothing
}
}
</script>

Have a great day!

~Secretxelf


Thanks, the code above works!!! I've been googling a similar problem for 2 days!

vb code = page.setfocus(control) and control.setfocus() and

html =<formid="form1"DefaultFocus="txtBox1n"runat="server">

don't work when you are using ajax updatepanel. The work around above does work.