In GridPanel, why column head's width is bigger than cell width?

  1. #1

    In GridPanel, why column head's width is bigger than cell width?

    Hi,
    I'm a freshman of Coolite. I have 3 questions:
    1.My Gridpanle's header width is bigger than cell, how can I adjust them to fit?(looks like in attachment)
    2.The PagingToolBar doesn't show correct page count, by the way, I use Coolite with asp.net mvc 1.0, that's a reason? I have 11 recodes in database, and set pagesize 10, so I think pagingToolBar should show 2 pages, but infact it's not work. Are my codes error?
    <asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
        <ext:Store ID="Store1" runat="server">
            <Proxy>
                <ext:HttpProxy 
                    Json="true" 
                    AutoDataBind="true" 
                    Url="AuditProject/ListAuditProjects" 
                    >
                </ext:HttpProxy>
            </Proxy>
            <Reader>
                <ext:JsonReader>
                    <Fields>
                        <ext:RecordField Name="CompanyName" Type="String" />
                        <ext:RecordField Name="AuditYear" Type="Int" />
                        <ext:RecordField Name="ProjectType"  Type="String"/>
                        <ext:RecordField Name="ProjectState" Type="String"/>
                    </Fields>
                </ext:JsonReader>
            </Reader>
            <BaseParams>
                <ext:Parameter Name="start" Value="0">
                </ext:Parameter>
                <ext:Parameter Name="limit" Value="10">
                </ext:Parameter>
            </BaseParams>
        </ext:Store>
        <ext:GridPanel 
            ID="GridPanel1" 
            runat="server" 
            StoreID="Store1" 
            Title="Project List"         
            StripeRows="true" 
            AutoDataBind="true"
            Height="400px" BodyBorder="True" EnableHdMenu="False">
            <ColumnModel runat="server" ID="ColumnModel1">
                <Columns>
                    <ext:Column DataIndex="CompanyName" Header="Company Name" MenuDisabled="true">
                    </ext:Column>
                    <ext:Column DataIndex="AuditYear" Header="Year" MenuDisabled="true">
                    </ext:Column>
                    <ext:Column DataIndex="ProjectType" Header="Project Type" MenuDisabled="true">
                    </ext:Column>
                    <ext:Column DataIndex="ProjectState" Header="State" MenuDisabled="true">
                    </ext:Column>
                </Columns>
            </ColumnModel>
            <BottomBar>
                <ext:PagingToolBar ID="PagingToolBar1" runat="server" PageSize="10" StoreID="Store1" DisplayInfo="false" AutoDataBind="True" AutoShow="True" AutoHeight="True" />
            </BottomBar>
            <LoadMask ShowMask="true" />
        </ext:GridPanel>
    </asp:Content>
    3.When I visit this page, usually jump a window tell me some error, why? And how can I fix it?(See attachment 2)

    Thanks
  2. #2

    RE: In GridPanel, why column head's width is bigger than cell width?

    Ok, the first question has been resolved. I deleted the default css style file site.css inclueded in Site.master, every thing is ok.

    Someone could answer other questions? It's hurry, Thanks lot!
  3. #3

    RE: In GridPanel, why column head's width is bigger than cell width?

    I think I find answer for question 3.
    I change the store's "Method" attribute from "default" to "Get", and everything is ok, no promp window jumped again.
    What means "default" to Method attribut? I strongly suggest Coolite should give us a fully API refenece and develope guide.
    Thanks.
  4. #4

    RE: In GridPanel, why column head's width is bigger than cell width?

    Now, question 2 about pagingtoolbar is only remained. Does anyone kown the answer? Please, help me.

    A new question: has anyone used Coolite with patial view technology, or dynamicly load a patial view?
  5. #5

    RE: In GridPanel, why column head's width is bigger than cell width?

    Thanks God, I found http://mvc.ext.net, a example web site which used Ext.NET with asp.net mvc. I sure my all questions can find answer from it.

    If you use Ext.NET in asp.net mvc project like me, try it!

    Thanks all again!
    Last edited by geoffrey.mcgill; Feb 22, 2011 at 4:32 AM.

Similar Threads

  1. Replies: 1
    Last Post: Jun 11, 2012, 11:59 AM
  2. Replies: 1
    Last Post: Jun 04, 2012, 3:48 PM
  3. Replies: 1
    Last Post: Nov 04, 2011, 8:51 AM
  4. [CLOSED] Grid Panel : Column width (Auto width)
    By legaldiscovery in forum 1.x Legacy Premium Help
    Replies: 4
    Last Post: Sep 24, 2011, 8:31 PM
  5. Replies: 6
    Last Post: Jun 11, 2010, 12:47 PM

Posting Permissions