Missing delete event listener

Posted by: davide.vago on 26 March 2020, 5:06 am EST

  • Posted 26 March 2020, 5:06 am EST

    Good morning/afternoon

    I'm currently trying to track whenever a user press the return key of the keyboard to delete a cell content but I can't find anything useful.

    I've been looking at this as well: https://www.grapecity.com/spreadjs/demos/features/workbook/spread-events/purejs

    Would you mind help me to find out a solution?
    Thanks in advance.
  • Replied 26 March 2020, 3:52 pm EST

    Hi Davide,

    I'm little confused here, return key is not used to delete the cell contents, were you referring to the 'backspace' or 'delete' key?
    For 'backspace' key, it simply puts the cell in edit mode, so you could just handle the 'EditEnded' event and check if the cell contents are cleared.
    For 'delete' key, you may handle the 'RangeChanged' event and check if the action type is of GC.Spread.Sheets.RangeChangedAction.clear.

    Please let me know if this doesn't resolve your issue.

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels