Include field & command in 1 column of Grid?

4 posts, 1 answers
  1. Bryan
    Bryan avatar
    3 posts
    Member since:
    May 2016

    Posted 24 May 2016 Link to this post


    Is it possible to have a command and field in 1 column of a Grid? Something along the lines of::

    Where in line number 11 below the 3 column would include the data value for products and a button (in this case just to edit the products for 1 line in grid) 

    01.var grid = $("#grid").kendoGrid({
    02.     dataSource: {
    03.          pageSize: 20,
    04.          data: createRandomData(50)
    05.     },
    06.     pageable: true,
    07.     height: 550,
    08.     columns: [
    09.          { field: "FirstName", title: "First Name", width: "140px" },
    10.          { field: "LastName", title: "Last Name", width: "140px" },
    11.          { field: "products", command: { text: "Edit Product List", click: showDetails }, title: " ", width: "180px" }                                                  ]


    Thanks in Advance 


  2. Answer
    Stephen avatar
    90 posts
    Member since:
    Jan 2011

    Posted 24 May 2016 in reply to Bryan Link to this post

    Try using a template for the column instead of a command and style as desired:



  3. Dimiter Madjarov
    Dimiter Madjarov avatar
    2312 posts

    Posted 25 May 2016 Link to this post

    Hello Bryan,

    I could confirm that using a template, which displays the field along with the command is the correct way to go here. Is this the desired behavior or we could provide further assistance?

    Dimiter Madjarov
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  4. Bryan
    Bryan avatar
    3 posts
    Member since:
    May 2016

    Posted 31 May 2016 Link to this post

    Thank You Stephen this is exactly what we were looking for, Regards. 
Back to Top