PDA

View Full Version : Error when TabScrolling in Cool TabPanel



Penunuri
Jun 16, 2008, 9:21 PM
Hi, good day !

I have a problem with a Cool TabPanel, in a aspx web page.

I have a Cool TabPanel, with several Tabs (about to 10), and set the EnableTabScroll="true" property.

In runtime, when I want to change the active Tab, after scrolling between them, an error raise and interrupts the system execution (in WebDeveloper, it open a document called "cool.axd [dynamic]", and shows a window with the text "htmlfile: Unknown name", and the code stops in the instruction "el.scrollLeft=val[0]").

Any clue about how to solve this error ?

Thanks very much in advance. You're doing an excellent work !!!

Regards

Alfonso Penunuri

geoffrey.mcgill
Jun 16, 2008, 10:05 PM
Hi Alfonso,

Please ensure you are using the latest build of the Toolkit. You can download the latest build from the following location.

http://www.ext.net/download/

Once you have your page working with the latest build, please confirm if error is still occuring.

You might have to provide a .aspx code sample demonstrating how to reproduce the problem.

What browser are you using?

Penunuri
Jun 17, 2008, 6:16 PM
Hi geoffrey !

Thanks for your support, and quick response.

I can figure out how to recreate the exact moment when the tab scrollin' create the error.

(Before, let me tell you that I'm using the latest version of Coolite (0.5), that I've download yesterday, and using Internet Explorer 7.0, under Windows Vista Ultimate).

It's caused by an UpdatePanel, incrusted above (outside) the TabPanel. If I remove the UpdatePanel, the Cool-TabPanel works very well. But if I use the UpdatePanel ('cause I need to use a PostBack when changing the active Tab), when I select a Tab that is partially hidden, or after scroll the TabPanel and select another Tab, an error occurs, stoping the execution in the code "I.scrollLeft=K[0]"

Here's the code that i used:



<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<%@ Register assembly="Coolite.Ext.Web" namespace="Coolite.Ext.Web" tagprefix="ext" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">


<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>Untitled Page</title>
<style type="text/css">
th {text-align:left;}th{font-style:normal;font-weight:normal;}
th{margin:0;padding:0;}</style>
</head>


<body>
<form id="form1" runat="server">
<asp:ScriptManager ID="ScriptManager1" runat="server" />
<ext:ScriptManager ID="ScriptManager2" runat="server" />

<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<ContentTemplate>
<ext:TabPanel ID="TabPanel1" runat="server" ActiveTab="0" Height="300px"
AutoPostBack="True" EnableTabScroll="True" ontabchanged="TabPanel1_TabChanged"
Title="TabPanel1" Width="449px" Plain="True">
<Tabs>
<ext:Tab ID="Tab1" runat="server" Title="Tab 1">
<Content>
</Content>
</ext:Tab>
<ext:Tab ID="Tab2" runat="server" Title="Tab 2">
<Content>
</Content>
</ext:Tab>
<ext:Tab ID="Tab3" runat="server" Title="Tab 3">
<Content>
</Content>
</ext:Tab>
<ext:Tab ID="ctl54" runat="server" Title="Tab 4">
</ext:Tab>
<ext:Tab ID="ctl56" runat="server" Title="Tab 5">
</ext:Tab>
<ext:Tab ID="ctl58" runat="server" Title="Tab 6">
</ext:Tab>
<ext:Tab ID="ctl74" runat="server" Title="Tab 7">
</ext:Tab>
<ext:Tab ID="ctl76" runat="server" Title="Tab 8">
</ext:Tab>
<ext:Tab ID="ctl78" runat="server" Title="Tab 9">
</ext:Tab>
<ext:Tab ID="ctl80" runat="server" Title="Tab 10">
</ext:Tab>
</Tabs>
</ext:TabPanel>
</ContentTemplate>
</asp:UpdatePanel>


</form>
</body>
</html>


And in the codebehind, supossed that I have:


protected void TabPanel1_TabChanged(object sender, EventArgs e)
{
string name = "Alfonso";
}


If you need any other info, please let me know. I hope this could be usefull for you to recreate my scenario.

Thanks so much ... and "salutes" from Mexico.

Alfonso Penunuri

geoffrey.mcgill
Jun 17, 2008, 6:59 PM
Hi Alfonso,

This is a known bug and unfortunately at the moment I do not have a solution to fix. I will spend some time on the later today and see if we can come up with a solution. For now, the only work-around is to not enable tab scrolling.

Penunuri
Jun 18, 2008, 7:18 PM
Hi geoffrey !

Thanks for all of your support.

I just have a final question ...

How can I use then the Cool-TabPanel with several Tabs, if they hide out in the design mode (and actually in run time) ?

Is there any property of the TabPanel when I can specify two levels of Tabs or something like that ?

Thanks in advance ...

Regards.

Alfonso Peņuņuri.

stevenoc
Jun 19, 2008, 5:48 PM
Hi Geoffrey,

I'm assuming that this is the same error that I forwarded to you "eons" ago :)

Is this still a problem with regards to the actual Ext Framework?

Regards
Steven O'Connor

geoffrey.mcgill
Jun 19, 2008, 5:56 PM
yep, same error. The bug is high on my list of things to fix, but at
the moment I just haven't found a feasible work-around. I'll try to put
some time into this one later today.

I apologize for the inconveinience.

stevenoc
Jun 19, 2008, 6:05 PM
For me its not much of an inconveinience as I've learned to live with the postback occuring :)

Just happy to know that its still on the list of many things to do (and with so little time in the day
to do it).

Its a nice to have if it could work inside of updatepanel.

Regards
Steven O'Connor