Collite buttons

  1. #1

    Collite buttons

    Hi guys, i am having some problems with coolite buttons and trying to open a window, heres my code:

    <!-- Contenido en Tabs con AJAX -->
                    <div id="tabs1">
                        <cool:TabPanel ID="TabPanel1" runat="server" ActiveTab="0" Height="300px" 
                            Plain="True" BodyStyle="padding:10px" ButtonAlign="Center">
                            <Items>
                                <cool:Tab ID="Tab1" runat="server" Title="Instructivo">
                                    <Content>
                                    <p>En este apartado tendr&amp;aacute; una gu&amp;iacute;a instructiva para el usuario...</p>
                                    </Content>
                                </cool:Tab>
                                <cool:Tab ID="Tab2" runat="server" Title="Reportes por Fecha" Width="300">
                                    <Content>
                                    <div id="tabsSearch1">
                                    <table class="tabsSearchTable1" cellspacing="4" width="0%">
                                    <tbody>
                                    <tr align="left" valign="top"><td>
                                    <asp:Label ID="searchLabel1" runat="server" Text="Fecha Inicial:"></asp:Label>
                                    </td>
                                    <td>
                                    <cool:DatePicker ID="DatePicker1" runat="server"></cool:DatePicker>
                                    </td></tr>
                                    <tr align="left" valign="top"><td>
                                    <asp:Label ID="Label1" runat="server" Text="Fecha Final:"></asp:Label>
                                    </td>
                                    <td>
                                    <cool:DatePicker ID="DatePicker2" runat="server"></cool:DatePicker>
                                    </td></tr>
                                    <tr align="left" valign="top"><td></td><td>
                                    <!-- <asp:Button ID="Button" runat="server" Text="Buscar" /> -->
                                    <cool:Button ID="Button1" runat="server" Text="Buscar"></cool:Button>
                                    </td></tr>
                                    </tbody>
                                    </table>
                                    
    
                                        <cool:Window
                                            ID="Window1"
                                            Title="Resultados"
                                            runat="server"
                                            Width="550px"
                                            Height="400px" 
                                            AutoShow="false"
                                            CloseAction="Hide"
                                            Collapsible="true"
                                            TriggerElement="Button1"
                                            AnimateTarget="Button1">
                                            <Content>
                                                <cool:Panel 
                                                    ID="Panel1" 
                                                    runat="server" 
                                                    Title="Reportes por Fecha"
                                                    Height="400px"
                                                    BodyStyle="padding: 6px;" 
                                                    AutoLoad="searchResult1.aspx"/>
                                            </Content>
                                        </cool:Window>                                 
                                    </Content>
                                </cool:Tab>
    As you can see, i have the asp button cotrol commented cause with that button the window opens perfectly... but no with coolite button... why?
    I am using lastest coolite 0.4.1

    Cheers.
  2. #2

    RE: Collite buttons

    Hi Gus,

    Thanks for pointing out the bug. The problem was two "click" events were getting registered to the Button and the _PostBack event was firing before the TriggerEvent to show the window. I put a couple checks to prevent this from happening.

    The code will be available with the next release.

    Until then, you can work-around this bug by removing the TriggerElement property from Window, and then add a Click event handler to the cool:Button to show the window. This is actually exactly what happens behind the scenes, but is just handled automatically. Manually adding the Click event will produce the exact same results.

    Example

    <cool:Button ID="Button1" runat="server" Text="Buscar">
        <ClientEvents>
            <Click Handler="function(){Window1.show();}" />
        </ClientEvents>
    </cool:Button>
    
    <cool:Window
        ID="Window1" 
        runat="server" 
        CloseAction="Hide">
        <Content>
            Window 1
        </Content>
    </cool:Window>
    Hope this helps

    Geoffrey McGill
    Founder
  3. #3

    RE: Collite buttons

    Thanks!! this solved the problem... indeed i hate asp.Net, but i offered my help in the Univ where i work to improve a site, which is made using asp .net... but like i am developer in other web and apps. languages (like Python and PyQt) it is not a problem for me to learn this.

    Anyway, this Coolite it is a great implementation (of Ext Js) for asp.net.

    Great Job!.


    Cheers and again thanks for the quick response.

Similar Threads

  1. Bad Buttons appear
    By java.controller in forum 1.x Help
    Replies: 2
    Last Post: Jul 10, 2010, 11:47 AM
  2. Collite in Opera?
    By jytu in forum 1.x Help
    Replies: 0
    Last Post: Jun 15, 2010, 9:06 AM
  3. [CLOSED] [1.0] Radio buttons that appear as buttons
    By MP in forum 1.x Legacy Premium Help
    Replies: 4
    Last Post: Mar 24, 2010, 6:28 PM
  4. may be buttons bug
    By pank in forum 1.x Help
    Replies: 0
    Last Post: Jun 14, 2009, 12:06 AM
  5. Image buttons / Custom built buttons
    By conman in forum 1.x Help
    Replies: 2
    Last Post: Jul 15, 2008, 11:01 AM

Posting Permissions