Author Topic: How to reset value of a cell  (Read 3421 times)

nghiemhd

  • Newbie
  • *
  • Posts: 16
    • View Profile
How to reset value of a cell
« on: May 29, 2014, 03:55:15 pm »
Hi pqgrid team,

I'm using inline editing feature of pqgrid. When users press tab from the cell that they want to edit, I will display a confirm dialog with yes/no button "Are you sure you want to save?".
If users click "No", I want pqgrid to reset value of that cell to the value before changed. How can I set value for the cell to the old value?

Thank you very much.

paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6310
    • View Profile
Re: How to reset value of a cell
« Reply #1 on: May 29, 2014, 10:44:16 pm »
use cellEditKeyDown event ( evt.keyCode == tab ) to display the confirm dialog box.

When users click no call quitEditMode method.

nghiemhd

  • Newbie
  • *
  • Posts: 16
    • View Profile
Re: How to reset value of a cell
« Reply #2 on: May 30, 2014, 08:37:04 am »
Dear team,

I have followed your instruction and it works well. Thank you very much.

Best regards,
Nghiem Hoang