Trapping the delete key in selected cells

Posted by: sumathi on 8 September 2017, 1:14 pm EST

  • Posted 8 September 2017, 1:14 pm EST

    Hello,


    I am designing the Windows application using C#.Net with farpoint spread sheets.


    I have designed some sheets. I have locked some cells/Columns.


    User should not be able to delete the data in these cells/columns.


    But using "Delete" key (from key board) it is allowing to delete the Locked cell containts also.


    Please help me how I can resolve this issue.

  • Replied 8 September 2017, 1:14 pm EST

    You should not be able to use the DEL key to remove the contents of the cell if it is truly locked.  Do you have a small project you could post that is showing this behavior?
  • Replied 8 September 2017, 1:14 pm EST

    Were you able to recreate this one?  I am having the same problem.  I've locked the cell, row, and column.  I cannot type into the cell, paste into the cell, etc.   But, if I hit the delete key, the contents of the cell is deleted.  I've even intercepted the KeyDown event and set e.Handled to true.
  • Replied 8 September 2017, 1:14 pm EST

    Hello,

    We are unable to replicate the issue at our end using the latest builds of Spread 5 and Spread 4 which is 5.0.3511.2008 and 4.0.3522.2008 wherein on Setting the cells , column or rows locked, we are unable to enter the cell's edit mode, hence unable to delete the Cells text on pressing Del Key or so.

    Please send us a small sample replicating the issue for us to debug further at our end and provide you with some solution. Thanks.

  • Replied 8 September 2017, 1:14 pm EST

    What we have noticed is that this only happens if the cell does not contain a formula.

  • Replied 8 September 2017, 1:14 pm EST

    Hello,

    Still I am unable to reproduce the issue. Could you please provide me with a sample replicating the issue as their must be something particular in your sample which would have been causing this.

    Thanks.

Need extra support?

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

Learn More

Forum Channels