View Full Version : [FIXED] [V0.6] AjaxEvent not working

Sep 09, 2008, 11:29 AM
Have problems with getting the AjaxEvent to work, I tried this examle from another thread
Im using 0.6 of Coolite, and IE 7. The active tabpage does not change, i just get the Ajax loader, and when finished loading nothing happens.

<%@ 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.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<script runat="server">

protected void Button1_Click(object obj, AjaxEventArgs e)
this.TabPanel1.ActiveTabIndex = 1;

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
<title>Coolite Toolkit : Setting the .ActiveTabIndex on an AjaxEvent</title>
<p><a href="ActiveTabIndex.aspx">Reload</a></p>
<form id="Form1" runat="server">
<ext:ScriptManager ID="ScriptManager1" runat="server" />
<ext:TabPanel ID="TabPanel1" runat="server" Height="300">
<ext:Tab ID="Tab1" runat="server" Title="Tab 1" Html="Tab 1" />
<ext:Tab ID="Tab2" runat="server" Title="Tab 2" Html="Tab 2" />
<ext:Button ID="Button1" runat="server" Text="Submit">
<Click OnEvent="Button1_Click" />

Best regards

Sep 09, 2008, 11:37 AM
Hello Jurke,

Have you registered Coolite Ajax in your Web.Config? Discussed here: http://forums.ext.net/showthread.php?threadid=1360-16-2.aspx and announced in the ReadMe.txt :)


Sep 09, 2008, 11:52 AM
Hi Mikael,

Can you check please that code in Button1_Click was executed (for example, under debug set breakpoint in Button1_Click)?

If code executed then please change the Button1_Click

protected void Button1_Click(object obj, AjaxEventArgs e)
this.TabPanel1.AddScript("alert('The request completed');");
this.TabPanel1.ActiveTabIndex = 1;

If all correct the after request you shouild see the alert window. Please let me know about results

Sep 09, 2008, 12:13 PM
Hi Guys
Thank you for your quick reply. It was my mistake, I have missed the web.config part. Im my defense, I just got the 0.6 dll by mail without the read me. :)

Its now working fine!

Best regards