View Full Version : [CLOSED] Panel Listeners: beforeActivate when panel within (or linked with) tabStrip

May 14, 2012, 6:36 PM

I have a tabstrip in my page. There are two panels linked with (or within of) this tabStrip.

1 - The listener 'beforeactivate' of panel is not triggered.
2 - The listener 'beforeShow' panel set on the tabStrip.activeTabIndex is not triggered when I run my application. If I click another tab and return to the original tab, the event is triggered.

My tests are made with this sample project:

<%@ Page Language="vb" %>
<%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<ext:ResourceManager ID="ResourceManager1" runat="server" />
<form id="form1" runat="server">

<ext:Viewport ID="Viewport2" runat="server" Layout="BorderLayout">
<ext:TabStrip ID="TabStrip1" runat="server" Region="North" ActiveTabIndex="1" >
<ext:Tab ActionItemID="test1" Text="Test 1" />
<ext:Tab ActionItemID="test2" Text="Test 2" />

<ext:Panel ID="test1" Title="test1" Html="teste 1">
<BeforeActivate Handler="alert('test 1 activated');" />
<BeforeShow Handler="alert('test 1 show!');" />
<ext:Panel ID="test2" Title="test2" Html="teste 2" >
<BeforeActivate Handler="alert('test 2 activated');" />
<BeforeShow Handler="alert('test 2 show!');" />

May 14, 2012, 9:45 PM

TabStrip doesn't support BeforeActivate and Activate event of its items.

Regarding to BeforeShow of initially activated tab. Generally, the component BeforeShow and Show are fired when that component is shown using its show method. The initially activated tab is just rendered, no call of show method.

You can:

1. Call a required script according to ActiveTabIndex property.

2. Set up

for the initially activated tab.

May 15, 2012, 12:47 PM
Hi Daniil!

Setting 'hide' property as true, works very fine!

Thanks a lot.