Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
125
Copying cell value to clipboard even if whole row is selected
posted

 Hello,

In my application there is WebGrid. I have added client side event on cellclick that programmatically selects row which clicked cell belongs to.It just invokes the setSelectes() method on active row. The problem is that i would like to keep the functionality of copying clicked cell value into clipboard even if clicking on the cell makes whole row selected. After adding this event whole row selects, which is fine, but values from all cells in that row copies into clipboard. The DisplayLayout CellClickActionDefault is set to CellSelect.

Regards,

powersystem

 

Parents
No Data
Reply
  • 28464
    posted

    Hello,

    I am not sure this one would be easy to implement, but maybe you can try this path - hook the client side BeforeClipboardOperation (or AfterClipobaord...) event of the grid documented here:

    http://help.infragistics.com/Help/NetAdvantage/NET/2007.2/CLR2.0/html/Infragistics2.WebUI.UltraWebGrid.v7.2~Infragistics.WebUI.UltraWebGrid.ClientSideEvents~BeforeClipboardOperation.html

    And try to explicitly change the clipboard with javascript in the event handler as described here:

    http://www.geekpedia.com/tutorial126_Clipboard-cut-copy-and-paste-with-JavaScript.html

    However this will only work in IE and could be tricky to do.

Children
No Data