This is a migrated thread and some comments may be shown as answers.

[Solved] Column Headings Not Scrolling

1 Answer 135 Views
Grid
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
steven
Top achievements
Rank 1
steven asked on 01 Jun 2011, 12:56 AM
Hi, I have a grid with 12 columns all with a fixed width.
I've enabled horizontal scrolling, but the headers for the columns do not scroll.
Any ideas how I could fix this ?
<%  Html.Telerik().Grid<NPI_Inventory_Development.Models.BAP_tbl_PO>("PurchaseOrders")        
     .TableHtmlAttributes(new { style = "table-layout:relative" })           
        
       .Name("Purchase Orders")
       .DataKeys(k => k.Add(o => o.intID))
       .Columns(c =>
       {
           c.Bound(d => d.intCPU_Model).Title("CPU Model").Width(150);
           c.Bound(d => d.intMB_Vendor).Title("MB Vendor").Width(150);
           c.Bound(d => d.strRAM).Title("RAM").Width(150);
           c.Bound(d => d.strHDD).Title("HDD").Width(150);
           c.Bound(d => d.strOD).Title("Optical Drive").Width(150);
           c.Bound(d => d.strPS).Title("Power Supply").Width(150);
           c.Bound(d => d.strNetwork).Title("Network Card").Width(150);
           c.Bound(d => d.strCase).Title("Case").Width(150);
           c.Bound(d => d.strMisc).Title("Misc.").Width(150);
           c.Bound(d => d.intQTY).Title("Qty.").Width(150);
           c.Bound(d => d.decTotal_Cost).Title("Total Cost").Width(150);
           c.Command(s =>
           {
               s.Edit();
               s.Delete();
           }).Width(150);
       })
 
       .ToolBar(t =>
        {
            t.Insert();
        }
       )
       .DataBinding(b => b.Server()
           .Insert("GridInsert", "Test")
           .Update("GridUpdate", "Test")
           .Delete("GridDelete", "Test")
       )                                                     
 
       .Pageable()
       .Sortable()
       .Filterable()
       .Scrollable(scrolling => scrolling.Height("auto"))                     
       .Render();          
   %>



1 Answer, 1 is accepted

Sort by
0
steven
Top achievements
Rank 1
answered on 01 Jun 2011, 03:35 AM
Please disregard, I changed .Name("Purchase Orders") to .Name("PurchaseOrders") and the column headings began working.

Tags
Grid
Asked by
steven
Top achievements
Rank 1
Answers by
steven
Top achievements
Rank 1
Share this question
or