Refresh button positioning

2 posts, 0 answers
  1. George
    George avatar
    7 posts
    Member since:
    Sep 2011

    Posted 06 Oct 2014 Link to this post

    I would like to position the refresh button at the top of the grid. Is that possible? The grid below is a sample of the code. (mostly default values)

    @(Html.Telerik().Grid(Model.DeleteableRules)

             
    .Name("DeleteableRulesGrid")

             
    .DataKeys(dk => dk.Add(dr => dr.ListID))

             
    .Selectable()

             
    .Columns(columns =>

              {

                 
    columns.Bound(dr => dr.ListID).HtmlAttributes(new
    { style = "width:100px;" });

                 
    columns.Bound(dr => dr.OrganizationID).HtmlAttributes(new { style = "width:100px;"
    });

                 
    columns.Bound(dr => dr.RuleName).HtmlAttributes(new
    { style = "width:300px;" });

                 
    columns.Bound(dr => dr.CurrentState).HtmlAttributes(new
    { style = "width:300px;" });

              })

     

              )



  2. Dimo
    Admin
    Dimo avatar
    8472 posts

    Posted 08 Oct 2014 Link to this post

    Hi George,

    The Refresh button cannot be moved to the top of the Grid, however, you can use a custom button with the same HTML markup, place it anywhere you prefer, and attach a click handler to it, which executes the read() method of the Grid dataSource.

    http://docs.telerik.com/kendo-ui/api/javascript/ui/grid#fields-dataSource

    http://docs.telerik.com/kendo-ui/api/javascript/data/datasource#methods-read

    Regards,
    Dimo
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
Back to Top