Copy to clipboard within Grid

2 posts, 0 answers
  1. Chris
    Chris avatar
    13 posts
    Member since:
    Dec 2011

    Posted 08 Sep 2017 Link to this post


    I'm wondering if there's an easy way to copy data from a specific row in a grid.  I have looked up examples however they have all dealt with copying the entire grid rather than data within specific rows.  A simple example would be a grid with two columns, the first contains the data to be copied within a standard GridBoundColumn and the second is a button (GridButtonColumn) to copy data from the row.  If I click the copy button for a given row it would copy the data contents (from the GridBoundColumn) for that given row and put it on the clipboard.  Is this possible?


  2. Eyup
    Eyup avatar
    4078 posts

    Posted 12 Sep 2017 Link to this post

    Hi Chris,

    You can achieve this requirement using the following steps:

    1. Pass the ItemIndex of the grid row to client-side:

    2. Access the item using the get_dataItems[index] method:

    3. Extract the text of the cell:

    4. Set the text content to the clipboard. This last step is not related to Telerik specifically and you can check various sources over the net on this matter:

    I hope this will prove helpful.

    Progress Telerik
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top